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

Add more summary fields to bulkWrite response

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.3.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Replication
    • Fully Compatible
    • Repl 2023-11-13

      See https://mongodb.slack.com/archives/C035ZJL6CQN/p1692638285661919 for more context

      We originally added numErrors as a summary field so the driver wouldn't have to iterate the cursor to see if any errors occurred. We want to provide the same for them for nInserted, nMatched, nModified, nUpserted, nDeleted so the driver can choose to not request a cursor (batchSize 0) and only return summary fields as an API option

      This ticket is to support these fields on both mongod and mongos

      This should also change numErorrs to nErrors for consistency with the new fields

      As part of this we should add singleBatch as an option to the bulkWrite command which will act the same as for other cursor commands (like find) where we only return the firstBatch and do not save the remaining results in a cursor to be fetched later

            Assignee:
            sean.zimmerman@mongodb.com Sean Zimmerman
            Reporter:
            sean.zimmerman@mongodb.com Sean Zimmerman
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: