-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Sharding
-
Fully Compatible
-
ALL
-
Sharding 2020-11-30, Sharding 2020-12-14
-
1
Problem Description
Recipient shards expect to read from the donor shard's existing sharded collection and the config.cache.chunks collection of the temporary resharding collection using {atClusterTime: <fetchTimestamp>}. Refreshing the temporary resharding collection on the donor shards causes them to create the config.cache.chunks.<database>.system.resharding.<existingUUID> collection. If this config.cache.chunks collection is created after the minFetchTimestamp, then the {atClusterTime: <fetchTimestamp>} read on it would fail with a SnapshotUnavailable error response. (Or a NamespaceNotFound error response if the donor shards weren't also recipient shards.)
Donor shards must instead create the config.cache.chunks for temporary resharding collection before calculating their minFetchTimestamp.
Solution
- Trigger a catalog cache refresh for the temporary resharding collection, on the DonorStateMachine, before calculating the fetchTimestamp.
- Remove the refresh that's marked under this ticket's number as a TODO on the coordinator's state machine.