-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 2.0.0
-
Component/s: None
-
None
With mongos / sharded cluster, Operation::Executable#execute incorrectly raises an exception. The following patch addresses this.
module Operation # added context.mongos? module Executable def execute(context) unless context.primary? || context.standalone? || context.mongos? || secondary_ok? raise Exception, "Must use primary server" end context.with_connection do |connection| connection.dispatch([ message ]) end end end end