Uploaded image for project: 'C++ Driver'
  1. C++ Driver
  2. CXX-926

Support sending writeConcern for commands that write

    • Type: Icon: New Feature New Feature
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None

      When talking with server 3.4 or greater (maxWireVersion >=5), writeConcern should be a supported option for commands that write.
      Helpers for the following commands therefore must be updated to support the option. The list is ordered according to likelihood that a driver has a helper for the command.

      • aggregate with $out
      • copydb
      • create
      • createIndexes
      • drop
      • dropDatabase
      • dropIndexes
      • mapReduce with $out
      • clone
      • cloneCollection
      • cloneCollectionAsCapped
      • collMod
      • convertToCapped
      • emptyCapped
      • renameCollection
      • appendoplognote
      • godInsert
      • capTrunc
      • reindex
        * mergechunk


      Note:

      When the writeConcern on a command that writes fails, the resulting document still comes back with ok: 1. Hence, to check for write concern and raise the appropriate error to your users, you will need to check the resulting document for a writeConcernError field. If it is present, then writeConcern failed.

            Assignee:
            backlog-cxx-driver [DO NOT USE] Backlog - CXX Driver Team
            Reporter:
            rathi.gnanasekaran Rathi Gnanasekaran
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: