-
Type: Task
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Sharding
-
Fully Compatible
-
Sharding 2018-08-13
As part of this ticket:
- Ensure ClusterDistinct supports readConcern level snapshot
- Ensure ClusterDistinct selects an appropriate atClusterTime based on the shards it targets, and will retry on snapshot errors
- Add unit tests verifying this works
Proposed implementation:
- Add a supportsReadConcern to ClusterDistinct that always returns true
- Update functions in cluster_commands_helpers.cpp to compute atClusterTime and attach it to the generated responses, like in ClusterAggregate (computing atClusterTime with computeAtClusterTime, attaching atClusterTime with appendAtClusterTime)
- snapshot errors are already retried in strategy.cpp, so there should be no work there
- Add unit test verify requests sent by ClusterDistinct contain appropriate atClusterTimes and are retried on snapshot errors, like the existing ClusterFind tests