diff options
author | Andreas Nilsson <andreas.nilsson@10gen.com> | 2015-08-28 18:52:42 -0400 |
---|---|---|
committer | Andreas Nilsson <andreas.nilsson@10gen.com> | 2015-09-07 20:50:11 -0400 |
commit | 7a3fa1f56d9cb121cae4d854f6ded2a12793077b (patch) | |
tree | de7fe1956ea2c506e085b490235cc6499924733b /src/mongo/db/auth/user_management_commands_parser.h | |
parent | 419b83ec4c3fbf637be32b9b94dc8fbc6a214461 (diff) | |
download | mongo-7a3fa1f56d9cb121cae4d854f6ded2a12793077b.tar.gz |
SERVER-20134 Restore the authSchemaUpgrade command
Diffstat (limited to 'src/mongo/db/auth/user_management_commands_parser.h')
-rw-r--r-- | src/mongo/db/auth/user_management_commands_parser.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/mongo/db/auth/user_management_commands_parser.h b/src/mongo/db/auth/user_management_commands_parser.h index c55210e8978..2bc278feecb 100644 --- a/src/mongo/db/auth/user_management_commands_parser.h +++ b/src/mongo/db/auth/user_management_commands_parser.h @@ -223,5 +223,19 @@ struct MergeAuthzCollectionsArgs { Status parseMergeAuthzCollectionsCommand(const BSONObj& cmdObj, MergeAuthzCollectionsArgs* parsedArgs); +struct AuthSchemaUpgradeArgs { + int maxSteps = 3; + bool shouldUpgradeShards = true; + BSONObj writeConcern; +}; + +/** + * Takes a command object describing an invocation of the "authSchemaUpgrade" command and + * parses out the write concern, maximum steps to take and whether or not shard servers should + * also be upgraded, in the sharded deployment case. + */ +Status parseAuthSchemaUpgradeCommand(const BSONObj& cmdObj, + const std::string& dbname, + AuthSchemaUpgradeArgs* parsedArgs); } // namespace auth } // namespace mongo |