-
Type: Task
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Execution
The goal of this ticket is to fix the known sharding issues with the write paths used when executing update/delete commands (or Batch/BulkWrite command containing update/delete operations) on sharded clusters.
As of today (Jan 22 2025), here is the list of known issues in the Query codebase that need to be fixed:
- SPM-3673: Fix updateOne by _id behavior re. chunk migrations for non-retryable writes
- SPM-1631: updateMany without shard key
- SERVER-20361: Improve the behaviour of multi-update/delete against a sharded collection
- SERVER-47371: Chunk migration concurrent with multi-delete can cause matching documents to not be deleted
- SERVER-86793: Retryable write may execute more than once in sharded clusters when collection namespace is reused after drop or rename
- SERVER-54019: Retryable write can report it matched and modified more documents than it actually did upon retry, due to interceding chunk migration
- SERVER-54127: Retryable write can execute more than once upon retry if a document moves between shards as a result of a shard key value update
- SERVER-XXXXX: Retryable write for ordered:true can execute a write statement for which the preceding write statement had a write error upon retry due to lack of bookkeeping for non-matching writes and no-op updates. This issue was mentioned in the "Known situations where contracts unmet" section of https://docs.google.com/document/d/1ttXQx6ZNMnU4JNdQRhV3nHSPk40TiwZpfG9emqn9ee8/edit?pli=1&tab=t.0#heading=h.udifr2rdegml . I couldn't find an existing Jira ticket for this issue.
- SERVER-YYYYY: UpdateOne/UpdateMany receive QueryPlanKilled in the presence of Resharding. This issue came from a discussion in November 2024 between kaloian.manassiev@mongodb.com and max.hirschhorn@mongodb.com . I couldn't find an existing Jira ticket for this issue.
- depends on
-
SERVER-20361 Improve the behaviour of multi-update/delete against a sharded collection
- Backlog
-
SERVER-47371 Chunk migration concurrent with multi-delete can cause matching documents to not be deleted
- Backlog
-
SERVER-54019 Session migration from moveChunk can lead to higher 'n' and 'nModified' for retryable updates by _id
- Backlog
-
SERVER-54127 Retryable update by _id may execute more than once if intervening write changes document's owning shard
- Backlog
-
SERVER-86793 Retryable write may execute more than once in sharded clusters when collection namespace is reused after drop or rename
- Backlog