-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Sharding
-
Fully Compatible
-
ALL
-
v4.4, v4.2
-
Sharding 2020-03-23, Sharding 2020-04-06
-
24
After cloning the initial documents in a chunk range, the recipient in a migration fetches any new writes in the range from the donor and applies them locally. For new inserts and updates, the recipient uses Helpers::upsert(), without handling write conflict exceptions, so a concurrent write to an already cloned document may abort the migration. This can happen in normal operation because multi writes targeted without the shard key are broadcast to all shards and do not filter orphans. I haven't reproduced this with transferred deletes, but from code inspection, the same problem seems possible.