-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: 6.0.0
-
Component/s: None
-
Catalog and Routing
-
Fully Compatible
-
ALL
-
-
CAR Team 2024-10-14
-
(copied to CRM)
-
200
-
1
During FCV upgrade from 5.0 to 6.0, we add the count of orphaned documents to each range deletion task. As part of this procedure, we do an index key scan of each orphaned range to get the number of documents. To do this, we are getting the shard key pattern from the range deletion task using the extractKeyPattern function.
However, this function does not work for hashed shard keys (SERVER-71806) - it will always return a range based shard key regardless of whether the shard key is actually hashed. This will cause users upgrading from 5.0 to 6.0 with range deletion tasks for collections with hashed shard keys to fail via this assertion.
We should not rely on the extractKeyPattern function to get the shard key for this procedure.
- related to
-
SERVER-71806 Review/fix usages of `ChunkRange::extractKeyPattern` and `Helpers::inferKeyPattern`
- Closed