Skip to content

Commit c7c07a8

Browse files
sdmeisnercolinsurprenant
authored andcommitted
Use latest stable mongo driver and fix the bug where BigDecimal.from_bson is calling an undefined method
1 parent 51358bd commit c7c07a8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/logstash/outputs/bson/big_decimal.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ module ClassMethods
4444
# @return [ BigDecimal ] The decoded BigDecimal.
4545
# @see http://bsonspec.org/#/specification
4646
def from_bson(bson)
47-
from_bson_double(bson.read(8))
47+
from_bson_double(bson.get_bytes(8))
4848
end
4949

5050
private

logstash-output-mongodb.gemspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Gem::Specification.new do |s|
2121
# Gem dependencies
2222
s.add_runtime_dependency "logstash-core-plugin-api", ">= 1.60", "<= 2.99"
2323
s.add_runtime_dependency 'logstash-codec-plain'
24-
s.add_runtime_dependency 'mongo', '~> 2.0.6'
24+
s.add_runtime_dependency 'mongo', '~> 2.6'
2525

2626
s.add_development_dependency 'logstash-devutils'
2727
end

0 commit comments

Comments
 (0)