Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-77872

Support updateOne without shard key

    • Type: Icon: Task Task
    • Resolution: Duplicate
    • Priority: Icon: Trivial - P5 Trivial - P5
    • None
    • Affects Version/s: None
    • Component/s: None
    • Replication

      BatchWriteExec and BulkWriteExec share the same sub-batching code which already handles targeting update/delete ops without shard key. For update/delete statements without shard key, bulkWrite will execute the two-phase write protocol similar to executeTwoPhaseWrite. In order to make the two-phase write protocol work for bulkWrite, we will need to make the _clusterQueryWithoutShardKey command and the _clusterWriteWithoutShardKey command recognize the bulkWrite command so that the two-phase protocol can construct proper read and write commands from the original bulkWrite statement and can return response in the desired syntax for the bulkWrite statement. Please see here for how “updateOne without shard key” works.

            Assignee:
            backlog-server-repl [DO NOT USE] Backlog - Replication Team
            Reporter:
            sean.zimmerman@mongodb.com Sean Zimmerman
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: