mongodb/mongo-ruby-driver — pull request #78 by hotchpotch (2011-12-28 06:19:40+00:00)
Title: rescue BSON serialize error when set :continue_on_error option.

When mongo bulk insert, I hope ignore bson serialize error.

require 'mongo'
data = [{'$invalid_key' => 'value'}, {'invalid.key' => 'value'}, {'key' => 'value'}]
coll = Mongo::Connection.new['testdb']['testcollection']
coll.insert(data, :continue_on_error => true) # Error

This pull request is rescue BSON serialize error when enable :continue_on_error option.