Perform a targeted update to stop broadcasting in random_moveChunk_with_maxkey_docs.js

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 9.0.0-rc1
    • Affects Version/s: None
    • Component/s: None
    • None
    • Cluster Scalability
    • Fully Compatible
    • ALL
    • ClusterScalability 22Jun-6Jul
    • 200
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      updateMaxKeyDoc in random_moveChunk_with_maxkey_docs.js updates by {_id: tracked._id} only, even though the collection is sharded on {skey: 1, otherKey: 1}. Without the shard key, mongos broadcasts the update to every shard.

      When this races a concurrent chunk migration, the write applies but the response's nModified is incorrect, so tracked.counter falls out of sync with the real doc.counter, failing inside the verifyMaxKeyDocs checks. The reason that nModified is incorrect is likely due to SERVER-54019.

       

      Fix: include the shard key in the filter so mongos targets one shard directly.

            Assignee:
            Kruti Shah
            Reporter:
            Kruti Shah
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: