-
Type: Task
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Labels:None
-
Cluster Scalability
There are currently 2 places that decides which index can be used as the shard key index. This ticket is to figure out if they can be refactored into a one place that makes these decisions.
The 2 places:
https://github.com/mongodb/mongo/blob/1e2a94cd7396709295f615de0437d854d72e54cd/src/mongo/db/catalog/index_catalog_impl.cpp#L1378
https://github.com/mongodb/mongo/blob/d589fdc86a615409f4fd85e2d73bbd48398753de/src/mongo/db/s/shard_key_util.cpp#L105