-
Type:
Bug
-
Resolution: Done
-
Priority:
Major - P3
-
None
-
Affects Version/s: 2.4.6, 2.5.2
-
Component/s: Sharding
-
None
-
Sharding
-
ALL
-
None
-
3
-
None
-
None
-
None
-
None
-
None
-
None
Send an insert to mongos at a time when mongod will have 'wassert' at the time of the write (nonetheless writing the document successfully). Sending getlasterror to mongos now causes it to return error when the write was successful. It appears that mongos goes by 'err' field from shard being populated and doesn't check the 'code' field (around https://github.com/mongodb/mongo/blame/master/src/mongo/s/strategy_shard.cpp#L686 ) so now most (all?) drivers report failure to the client.