diff options
Diffstat (limited to 'src/mongo/db/server_options_helpers.h')
-rw-r--r-- | src/mongo/db/server_options_helpers.h | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/src/mongo/db/server_options_helpers.h b/src/mongo/db/server_options_helpers.h index f97ab00e795..88002c7228b 100644 --- a/src/mongo/db/server_options_helpers.h +++ b/src/mongo/db/server_options_helpers.h @@ -62,7 +62,21 @@ Status validateServerOptions(const moe::Environment& params); */ Status canonicalizeServerOptions(moe::Environment* params); -Status storeServerOptions(const moe::Environment& params, const std::vector<std::string>& args); +/** + * Sets up the global server state necessary to be able to store the server options, based on how + * the server was started. + * + * For example, saves the current working directory in serverGlobalParams.cwd so that relative paths + * in server options can be interpreted correctly. + */ +Status setupServerOptions(const std::vector<std::string>& args); + +/** + * Store the given parsed params in global server state. + * + * For example, sets the serverGlobalParams.port variable based on the net.port config parameter. + */ +Status storeServerOptions(const moe::Environment& params); void printCommandLineOpts(); |