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

authSchemaUpgrade overrides writeConcern sent to individual shards

    • Type: Icon: Bug Bug
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Querying, Sharding
    • None
    • Sharding
    • ALL

      mongos sends the authSchemaUpgrade command to each individual shard here, but provides a 30sec wtimeout and writeConcern majority rather than passing on what the user gave it. The command object is built here:

          BSONObjBuilder cmdObjBuilder;
          cmdObjBuilder.append("authSchemaUpgrade", 1);
          cmdObjBuilder.append("maxSteps", maxSteps);
          cmdObjBuilder.append("writeConcern", kMajorityWriteConcern.toBSON());
      

      with the following hard-coded writeConcern:

      const WriteConcernOptions kMajorityWriteConcern(WriteConcernOptions::kMajority,
                                                      // Note: Even though we're setting UNSET here,
                                                      // kMajority implies JOURNAL if journaling is
                                                      // supported by this mongod.
                                                      WriteConcernOptions::SyncMode::UNSET,
                                                      Seconds(30));
      

            Assignee:
            backlog-server-sharding [DO NOT USE] Backlog - Sharding Team
            Reporter:
            judah.schvimer@mongodb.com Judah Schvimer
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: