[SERVER-27341] authSchemaUpgrade overrides writeConcern sent to individual shards Created: 08/Dec/16  Updated: 06/Dec/22  Resolved: 02/Jan/20

Status: Closed
Project: Core Server
Component/s: Querying, Sharding
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Judah Schvimer Assignee: [DO NOT USE] Backlog - Sharding Team
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Sharding
Operating System: ALL
Participants:

 Description   

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));



 Comments   
Comment by Sheeri Cabral (Inactive) [ 02/Jan/20 ]

Not pervasive enough in the wild to fix.

Generated at Thu Feb 08 04:14:53 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.