summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mongo/db/commands.cpp3
-rw-r--r--src/mongo/db/commands.h13
-rw-r--r--src/mongo/db/commands/conn_pool_sync.cpp2
-rw-r--r--src/mongo/db/commands/dbcommands.cpp8
-rw-r--r--src/mongo/db/commands/dbhash.cpp2
-rw-r--r--src/mongo/db/commands/drop_indexes.cpp2
-rw-r--r--src/mongo/db/commands/eval.cpp2
-rw-r--r--src/mongo/db/commands/find_and_modify.cpp2
-rw-r--r--src/mongo/db/commands/generic.cpp8
-rw-r--r--src/mongo/db/commands/get_last_error.cpp6
-rw-r--r--src/mongo/db/commands/list_databases.cpp2
-rw-r--r--src/mongo/db/commands/lock_info.cpp2
-rw-r--r--src/mongo/db/commands/mr.cpp2
-rw-r--r--src/mongo/db/commands/pipeline_command.cpp2
-rw-r--r--src/mongo/db/commands/server_status.cpp2
-rw-r--r--src/mongo/db/commands/top_command.cpp2
-rw-r--r--src/mongo/db/repl/repl_set_command.h2
-rw-r--r--src/mongo/db/repl/repl_set_commands.cpp4
-rw-r--r--src/mongo/db/repl/replication_info.cpp2
-rw-r--r--src/mongo/db/s/check_sharding_index_command.cpp2
-rw-r--r--src/mongo/db/s/split_vector_command.cpp2
-rw-r--r--src/mongo/s/commands/cluster_add_shard_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_add_shard_to_zone_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_available_query_options_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_count_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_db_stats_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_enable_sharding_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_find_and_modify_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_flush_router_config_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_fsync_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_get_last_error_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_get_prev_error_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_get_shard_version_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_is_master_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_list_databases_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_list_shards_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_map_reduce_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_move_chunk_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_move_primary_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_netstat_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_pipeline_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_profile_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_remove_shard_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_remove_shard_from_zone_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_reset_error_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_shard_collection_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_split_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_update_zone_key_range_cmd.cpp2
-rw-r--r--src/mongo/s/commands/commands_public.cpp4
49 files changed, 59 insertions, 71 deletions
diff --git a/src/mongo/db/commands.cpp b/src/mongo/db/commands.cpp
index 5d52a83ca17..607c0d59430 100644
--- a/src/mongo/db/commands.cpp
+++ b/src/mongo/db/commands.cpp
@@ -137,9 +137,8 @@ ResourcePattern Command::parseResourcePattern(const std::string& dbname,
return ResourcePattern::forExactNamespace(NamespaceString(ns));
}
-Command::Command(StringData name, bool webUI, StringData oldName)
+Command::Command(StringData name, StringData oldName)
: _name(name.toString()),
- _webUI(webUI),
_commandsExecutedMetric("commands." + _name + ".total", &_commandsExecuted),
_commandsFailedMetric("commands." + _name + ".failed", &_commandsFailed) {
// register ourself.
diff --git a/src/mongo/db/commands.h b/src/mongo/db/commands.h
index 39246d357a2..2c55575dce5 100644
--- a/src/mongo/db/commands.h
+++ b/src/mongo/db/commands.h
@@ -89,10 +89,9 @@ public:
* Constructs a new command and causes it to be registered with the global commands list. It is
* not safe to construct commands other than when the server is starting up.
*
- * @param webUI expose the command in the web ui as localhost:28017/<name>
* @param oldName an optional old, deprecated name for the command
*/
- Command(StringData name, bool webUI = false, StringData oldName = StringData());
+ Command(StringData name, StringData oldName = StringData());
// NOTE: Do not remove this declaration, or relocate it in this class. We
// are using this method to control where the vtable is emitted.
@@ -105,13 +104,6 @@ public:
return _name;
}
- /**
- * Returns whether this command is visible in the Web UI.
- */
- bool isWebUI() const {
- return _webUI;
- }
-
// Return the namespace for the command. If the first field in 'cmdObj' is of type
// mongo::String, then that field is interpreted as the collection name, and is
// appended to 'dbname' after a '.' character. If the first field is not of type
@@ -436,9 +428,6 @@ private:
// The full name of the command
const std::string _name;
- // Whether the command is available in the web UI
- const bool _webUI;
-
// Pointers to hold the metrics tree references
ServerStatusMetricField<Counter64> _commandsExecutedMetric;
ServerStatusMetricField<Counter64> _commandsFailedMetric;
diff --git a/src/mongo/db/commands/conn_pool_sync.cpp b/src/mongo/db/commands/conn_pool_sync.cpp
index 84ba902d4ac..602f6e8421d 100644
--- a/src/mongo/db/commands/conn_pool_sync.cpp
+++ b/src/mongo/db/commands/conn_pool_sync.cpp
@@ -39,7 +39,7 @@ namespace mongo {
class PoolFlushCmd : public Command {
public:
- PoolFlushCmd() : Command("connPoolSync", false, "connpoolsync") {}
+ PoolFlushCmd() : Command("connPoolSync", "connpoolsync") {}
virtual void help(std::stringstream& help) const {
help << "internal";
}
diff --git a/src/mongo/db/commands/dbcommands.cpp b/src/mongo/db/commands/dbcommands.cpp
index 80a41c682f7..f41d6a2ae2b 100644
--- a/src/mongo/db/commands/dbcommands.cpp
+++ b/src/mongo/db/commands/dbcommands.cpp
@@ -825,7 +825,7 @@ class CmdDatasize : public Command {
}
public:
- CmdDatasize() : Command("dataSize", false, "datasize") {}
+ CmdDatasize() : Command("dataSize", "datasize") {}
virtual bool slaveOk() const {
return true;
@@ -975,7 +975,7 @@ public:
class CollectionStats : public Command {
public:
- CollectionStats() : Command("collStats", false, "collstats") {}
+ CollectionStats() : Command("collStats", "collstats") {}
virtual bool slaveOk() const {
return true;
@@ -1058,7 +1058,7 @@ public:
class DBStats : public Command {
public:
- DBStats() : Command("dbStats", false, "dbstats") {}
+ DBStats() : Command("dbStats", "dbstats") {}
virtual bool slaveOk() const {
return true;
@@ -1176,7 +1176,7 @@ public:
class AvailableQueryOptions : public Command {
public:
- AvailableQueryOptions() : Command("availableQueryOptions", false, "availablequeryoptions") {}
+ AvailableQueryOptions() : Command("availableQueryOptions", "availablequeryoptions") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/db/commands/dbhash.cpp b/src/mongo/db/commands/dbhash.cpp
index e554c3b7bdc..598fe1aad7c 100644
--- a/src/mongo/db/commands/dbhash.cpp
+++ b/src/mongo/db/commands/dbhash.cpp
@@ -60,7 +60,7 @@ namespace {
class DBHashCmd : public Command {
public:
- DBHashCmd() : Command("dbHash", false, "dbhash") {}
+ DBHashCmd() : Command("dbHash", "dbhash") {}
virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
return false;
diff --git a/src/mongo/db/commands/drop_indexes.cpp b/src/mongo/db/commands/drop_indexes.cpp
index 12ccc5408f9..0a78963ad1f 100644
--- a/src/mongo/db/commands/drop_indexes.cpp
+++ b/src/mongo/db/commands/drop_indexes.cpp
@@ -83,7 +83,7 @@ public:
out->push_back(Privilege(parseResourcePattern(dbname, cmdObj), actions));
}
- CmdDropIndexes() : Command("dropIndexes", false, "deleteIndexes") {}
+ CmdDropIndexes() : Command("dropIndexes", "deleteIndexes") {}
bool run(OperationContext* opCtx,
const string& dbname,
BSONObj& jsobj,
diff --git a/src/mongo/db/commands/eval.cpp b/src/mongo/db/commands/eval.cpp
index 511c5c0c4cb..3a11e45e11f 100644
--- a/src/mongo/db/commands/eval.cpp
+++ b/src/mongo/db/commands/eval.cpp
@@ -172,7 +172,7 @@ public:
RoleGraph::generateUniversalPrivileges(out);
}
- CmdEval() : Command("eval", false, "$eval") {}
+ CmdEval() : Command("eval", "$eval") {}
bool run(OperationContext* opCtx,
const string& dbname,
diff --git a/src/mongo/db/commands/find_and_modify.cpp b/src/mongo/db/commands/find_and_modify.cpp
index ce8abf5ab8c..5ec268571e5 100644
--- a/src/mongo/db/commands/find_and_modify.cpp
+++ b/src/mongo/db/commands/find_and_modify.cpp
@@ -228,7 +228,7 @@ public:
"Output is in the \"value\" field\n";
}
- CmdFindAndModify() : Command("findAndModify", false, "findandmodify") {}
+ CmdFindAndModify() : Command("findAndModify", "findandmodify") {}
bool slaveOk() const override {
return false;
diff --git a/src/mongo/db/commands/generic.cpp b/src/mongo/db/commands/generic.cpp
index 082128ebf74..0a54dc74bbb 100644
--- a/src/mongo/db/commands/generic.cpp
+++ b/src/mongo/db/commands/generic.cpp
@@ -71,7 +71,7 @@ using std::vector;
class CmdBuildInfo : public Command {
public:
- CmdBuildInfo() : Command("buildInfo", true, "buildinfo") {}
+ CmdBuildInfo() : Command("buildInfo", "buildinfo") {}
virtual bool slaveOk() const {
return true;
}
@@ -130,7 +130,7 @@ public:
class FeaturesCmd : public Command {
public:
- FeaturesCmd() : Command("features", true) {}
+ FeaturesCmd() : Command("features") {}
void help(stringstream& h) const {
h << "return build level feature settings";
}
@@ -165,7 +165,7 @@ public:
class HostInfoCmd : public Command {
public:
- HostInfoCmd() : Command("hostInfo", true) {}
+ HostInfoCmd() : Command("hostInfo") {}
virtual bool slaveOk() const {
return true;
}
@@ -250,7 +250,7 @@ public:
virtual void help(stringstream& help) const {
help << "get a list of all db commands";
}
- ListCommandsCmd() : Command("listCommands", false) {}
+ ListCommandsCmd() : Command("listCommands") {}
virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
return false;
}
diff --git a/src/mongo/db/commands/get_last_error.cpp b/src/mongo/db/commands/get_last_error.cpp
index 14e9c4fbf33..e153de58188 100644
--- a/src/mongo/db/commands/get_last_error.cpp
+++ b/src/mongo/db/commands/get_last_error.cpp
@@ -69,7 +69,7 @@ public:
virtual void help(stringstream& help) const {
help << "reset error state (used with getpreverror)";
}
- CmdResetError() : Command("resetError", false, "reseterror") {}
+ CmdResetError() : Command("resetError", "reseterror") {}
bool run(OperationContext* opCtx,
const string& db,
BSONObj& cmdObj,
@@ -82,7 +82,7 @@ public:
class CmdGetLastError : public Command {
public:
- CmdGetLastError() : Command("getLastError", false, "getlasterror") {}
+ CmdGetLastError() : Command("getLastError", "getlasterror") {}
virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
return false;
}
@@ -310,7 +310,7 @@ public:
virtual void addRequiredPrivileges(const std::string& dbname,
const BSONObj& cmdObj,
std::vector<Privilege>* out) {} // No auth required
- CmdGetPrevError() : Command("getPrevError", false, "getpreverror") {}
+ CmdGetPrevError() : Command("getPrevError", "getpreverror") {}
bool run(OperationContext* opCtx,
const string& dbname,
BSONObj& cmdObj,
diff --git a/src/mongo/db/commands/list_databases.cpp b/src/mongo/db/commands/list_databases.cpp
index 4b3be3b27db..d71d9ab3abb 100644
--- a/src/mongo/db/commands/list_databases.cpp
+++ b/src/mongo/db/commands/list_databases.cpp
@@ -81,7 +81,7 @@ public:
out->push_back(Privilege(ResourcePattern::forClusterResource(), actions));
}
- CmdListDatabases() : Command("listDatabases", true) {}
+ CmdListDatabases() : Command("listDatabases") {}
bool run(OperationContext* opCtx,
const string& dbname,
diff --git a/src/mongo/db/commands/lock_info.cpp b/src/mongo/db/commands/lock_info.cpp
index 3bb198f78f4..9318f734c9f 100644
--- a/src/mongo/db/commands/lock_info.cpp
+++ b/src/mongo/db/commands/lock_info.cpp
@@ -77,7 +77,7 @@ public:
return isAuthorized ? Status::OK() : Status(ErrorCodes::Unauthorized, "Unauthorized");
}
- CmdLockInfo() : Command("lockInfo", true) {}
+ CmdLockInfo() : Command("lockInfo") {}
bool run(OperationContext* opCtx,
const string& dbname,
diff --git a/src/mongo/db/commands/mr.cpp b/src/mongo/db/commands/mr.cpp
index 6e5213052ca..e4463ad7c1a 100644
--- a/src/mongo/db/commands/mr.cpp
+++ b/src/mongo/db/commands/mr.cpp
@@ -1341,7 +1341,7 @@ BSONObj _bailFromJS(const BSONObj& args, void* data) {
*/
class MapReduceCommand : public Command {
public:
- MapReduceCommand() : Command("mapReduce", false, "mapreduce") {}
+ MapReduceCommand() : Command("mapReduce", "mapreduce") {}
virtual bool slaveOk() const {
return repl::getGlobalReplicationCoordinator()->getReplicationMode() !=
diff --git a/src/mongo/db/commands/pipeline_command.cpp b/src/mongo/db/commands/pipeline_command.cpp
index 8a133a7185c..9f21d3825db 100644
--- a/src/mongo/db/commands/pipeline_command.cpp
+++ b/src/mongo/db/commands/pipeline_command.cpp
@@ -47,7 +47,7 @@ bool isMergePipeline(const std::vector<BSONObj>& pipeline) {
class PipelineCommand : public Command {
public:
- PipelineCommand() : Command("aggregate", false) {}
+ PipelineCommand() : Command("aggregate") {}
void help(std::stringstream& help) const override {
help << "Runs the aggregation command. See http://dochub.mongodb.org/core/aggregation for "
diff --git a/src/mongo/db/commands/server_status.cpp b/src/mongo/db/commands/server_status.cpp
index 530e6cf8618..212498d178b 100644
--- a/src/mongo/db/commands/server_status.cpp
+++ b/src/mongo/db/commands/server_status.cpp
@@ -66,7 +66,7 @@ using std::stringstream;
class CmdServerStatus : public Command {
public:
- CmdServerStatus() : Command("serverStatus", true), _started(Date_t::now()), _runCalled(false) {}
+ CmdServerStatus() : Command("serverStatus"), _started(Date_t::now()), _runCalled(false) {}
virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
return false;
diff --git a/src/mongo/db/commands/top_command.cpp b/src/mongo/db/commands/top_command.cpp
index 0837e9a2d92..8f306df9838 100644
--- a/src/mongo/db/commands/top_command.cpp
+++ b/src/mongo/db/commands/top_command.cpp
@@ -44,7 +44,7 @@ using namespace mongo;
class TopCommand : public Command {
public:
- TopCommand() : Command("top", true) {}
+ TopCommand() : Command("top") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/db/repl/repl_set_command.h b/src/mongo/db/repl/repl_set_command.h
index 3eb2275a064..1997b2b29a3 100644
--- a/src/mongo/db/repl/repl_set_command.h
+++ b/src/mongo/db/repl/repl_set_command.h
@@ -45,7 +45,7 @@ namespace repl {
*/
class ReplSetCommand : public Command {
protected:
- ReplSetCommand(const char* s, bool show = false) : Command(s, show) {}
+ ReplSetCommand(const char* s) : Command(s) {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/db/repl/repl_set_commands.cpp b/src/mongo/db/repl/repl_set_commands.cpp
index d48bd0537df..b2ab4c3bc04 100644
--- a/src/mongo/db/repl/repl_set_commands.cpp
+++ b/src/mongo/db/repl/repl_set_commands.cpp
@@ -187,7 +187,7 @@ public:
help << "{ replSetGetStatus : 1 }";
help << "\nhttp://dochub.mongodb.org/core/replicasetcommands";
}
- CmdReplSetGetStatus() : ReplSetCommand("replSetGetStatus", true) {}
+ CmdReplSetGetStatus() : ReplSetCommand("replSetGetStatus") {}
virtual bool run(OperationContext* opCtx,
const string&,
BSONObj& cmdObj,
@@ -228,7 +228,7 @@ public:
help << "{ replSetGetConfig : 1 }";
help << "\nhttp://dochub.mongodb.org/core/replicasetcommands";
}
- CmdReplSetGetConfig() : ReplSetCommand("replSetGetConfig", true) {}
+ CmdReplSetGetConfig() : ReplSetCommand("replSetGetConfig") {}
virtual bool run(OperationContext* opCtx,
const string&,
BSONObj& cmdObj,
diff --git a/src/mongo/db/repl/replication_info.cpp b/src/mongo/db/repl/replication_info.cpp
index 1398ebaed7a..dacefa5f72e 100644
--- a/src/mongo/db/repl/replication_info.cpp
+++ b/src/mongo/db/repl/replication_info.cpp
@@ -230,7 +230,7 @@ public:
virtual void addRequiredPrivileges(const std::string& dbname,
const BSONObj& cmdObj,
std::vector<Privilege>* out) {} // No auth required
- CmdIsMaster() : Command("isMaster", true, "ismaster") {}
+ CmdIsMaster() : Command("isMaster", "ismaster") {}
virtual bool run(OperationContext* opCtx,
const string&,
BSONObj& cmdObj,
diff --git a/src/mongo/db/s/check_sharding_index_command.cpp b/src/mongo/db/s/check_sharding_index_command.cpp
index 61a126928ce..e274dbaa7a9 100644
--- a/src/mongo/db/s/check_sharding_index_command.cpp
+++ b/src/mongo/db/s/check_sharding_index_command.cpp
@@ -56,7 +56,7 @@ namespace {
class CheckShardingIndex : public Command {
public:
- CheckShardingIndex() : Command("checkShardingIndex", false) {}
+ CheckShardingIndex() : Command("checkShardingIndex") {}
virtual void help(std::stringstream& help) const {
help << "Internal command.\n";
diff --git a/src/mongo/db/s/split_vector_command.cpp b/src/mongo/db/s/split_vector_command.cpp
index d79dd271227..19f5951e616 100644
--- a/src/mongo/db/s/split_vector_command.cpp
+++ b/src/mongo/db/s/split_vector_command.cpp
@@ -71,7 +71,7 @@ BSONObj prettyKey(const BSONObj& keyPattern, const BSONObj& key) {
class SplitVector : public Command {
public:
- SplitVector() : Command("splitVector", false) {}
+ SplitVector() : Command("splitVector") {}
bool supportsWriteConcern(const BSONObj& cmd) const override {
return false;
diff --git a/src/mongo/s/commands/cluster_add_shard_cmd.cpp b/src/mongo/s/commands/cluster_add_shard_cmd.cpp
index dafc4b0ef30..15b20ae43e2 100644
--- a/src/mongo/s/commands/cluster_add_shard_cmd.cpp
+++ b/src/mongo/s/commands/cluster_add_shard_cmd.cpp
@@ -53,7 +53,7 @@ const char kShardAdded[] = "shardAdded";
class AddShardCmd : public Command {
public:
- AddShardCmd() : Command("addShard", false, "addshard") {}
+ AddShardCmd() : Command("addShard", "addshard") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_add_shard_to_zone_cmd.cpp b/src/mongo/s/commands/cluster_add_shard_to_zone_cmd.cpp
index aa6917903ca..a6981ccbaab 100644
--- a/src/mongo/s/commands/cluster_add_shard_to_zone_cmd.cpp
+++ b/src/mongo/s/commands/cluster_add_shard_to_zone_cmd.cpp
@@ -67,7 +67,7 @@ const WriteConcernOptions kMajorityWriteConcern(WriteConcernOptions::kMajority,
*/
class AddShardToZoneCmd : public Command {
public:
- AddShardToZoneCmd() : Command("addShardToZone", false, "addshardtozone") {}
+ AddShardToZoneCmd() : Command("addShardToZone", "addshardtozone") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_available_query_options_cmd.cpp b/src/mongo/s/commands/cluster_available_query_options_cmd.cpp
index e49bc1708d3..8db71cb997b 100644
--- a/src/mongo/s/commands/cluster_available_query_options_cmd.cpp
+++ b/src/mongo/s/commands/cluster_available_query_options_cmd.cpp
@@ -37,7 +37,7 @@ namespace {
class AvailableQueryOptions : public Command {
public:
- AvailableQueryOptions() : Command("availableQueryOptions", false, "availablequeryoptions") {}
+ AvailableQueryOptions() : Command("availableQueryOptions", "availablequeryoptions") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_count_cmd.cpp b/src/mongo/s/commands/cluster_count_cmd.cpp
index 6187b17f037..9f5d842fce9 100644
--- a/src/mongo/s/commands/cluster_count_cmd.cpp
+++ b/src/mongo/s/commands/cluster_count_cmd.cpp
@@ -49,7 +49,7 @@ namespace {
class ClusterCountCmd : public Command {
public:
- ClusterCountCmd() : Command("count", false) {}
+ ClusterCountCmd() : Command("count") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_db_stats_cmd.cpp b/src/mongo/s/commands/cluster_db_stats_cmd.cpp
index 3317fdd07ce..f89e54365ef 100644
--- a/src/mongo/s/commands/cluster_db_stats_cmd.cpp
+++ b/src/mongo/s/commands/cluster_db_stats_cmd.cpp
@@ -42,7 +42,7 @@ using std::vector;
class DBStatsCmd : public Command {
public:
- DBStatsCmd() : Command("dbStats", false, "dbstats") {}
+ DBStatsCmd() : Command("dbStats", "dbstats") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_enable_sharding_cmd.cpp b/src/mongo/s/commands/cluster_enable_sharding_cmd.cpp
index a5716d67797..f3e9b7368e5 100644
--- a/src/mongo/s/commands/cluster_enable_sharding_cmd.cpp
+++ b/src/mongo/s/commands/cluster_enable_sharding_cmd.cpp
@@ -49,7 +49,7 @@ namespace {
class EnableShardingCmd : public Command {
public:
- EnableShardingCmd() : Command("enableSharding", false, "enablesharding") {}
+ EnableShardingCmd() : Command("enableSharding", "enablesharding") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_find_and_modify_cmd.cpp b/src/mongo/s/commands/cluster_find_and_modify_cmd.cpp
index ee23438a2fb..225567b3ebd 100644
--- a/src/mongo/s/commands/cluster_find_and_modify_cmd.cpp
+++ b/src/mongo/s/commands/cluster_find_and_modify_cmd.cpp
@@ -60,7 +60,7 @@ using std::vector;
class FindAndModifyCmd : public Command {
public:
- FindAndModifyCmd() : Command("findAndModify", false, "findandmodify") {}
+ FindAndModifyCmd() : Command("findAndModify", "findandmodify") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_flush_router_config_cmd.cpp b/src/mongo/s/commands/cluster_flush_router_config_cmd.cpp
index b61b2b4ccba..5d36aba4723 100644
--- a/src/mongo/s/commands/cluster_flush_router_config_cmd.cpp
+++ b/src/mongo/s/commands/cluster_flush_router_config_cmd.cpp
@@ -37,7 +37,7 @@ namespace {
class FlushRouterConfigCmd : public Command {
public:
- FlushRouterConfigCmd() : Command("flushRouterConfig", false, "flushrouterconfig") {}
+ FlushRouterConfigCmd() : Command("flushRouterConfig", "flushrouterconfig") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_fsync_cmd.cpp b/src/mongo/s/commands/cluster_fsync_cmd.cpp
index 8237934d675..28b907a061d 100644
--- a/src/mongo/s/commands/cluster_fsync_cmd.cpp
+++ b/src/mongo/s/commands/cluster_fsync_cmd.cpp
@@ -40,7 +40,7 @@ namespace {
class FsyncCommand : public Command {
public:
- FsyncCommand() : Command("fsync", false, "fsync") {}
+ FsyncCommand() : Command("fsync", "fsync") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_get_last_error_cmd.cpp b/src/mongo/s/commands/cluster_get_last_error_cmd.cpp
index 1d9b9021bae..39eb26a61f6 100644
--- a/src/mongo/s/commands/cluster_get_last_error_cmd.cpp
+++ b/src/mongo/s/commands/cluster_get_last_error_cmd.cpp
@@ -186,7 +186,7 @@ Status enforceLegacyWriteConcern(OperationContext* opCtx,
class GetLastErrorCmd : public Command {
public:
- GetLastErrorCmd() : Command("getLastError", false, "getlasterror") {}
+ GetLastErrorCmd() : Command("getLastError", "getlasterror") {}
virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
return false;
diff --git a/src/mongo/s/commands/cluster_get_prev_error_cmd.cpp b/src/mongo/s/commands/cluster_get_prev_error_cmd.cpp
index 58d776293d8..97d96e3e322 100644
--- a/src/mongo/s/commands/cluster_get_prev_error_cmd.cpp
+++ b/src/mongo/s/commands/cluster_get_prev_error_cmd.cpp
@@ -40,7 +40,7 @@ namespace {
class GetPrevErrorCmd : public Command {
public:
- GetPrevErrorCmd() : Command("getPrevError", false, "getpreverror") {}
+ GetPrevErrorCmd() : Command("getPrevError", "getpreverror") {}
virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
diff --git a/src/mongo/s/commands/cluster_get_shard_version_cmd.cpp b/src/mongo/s/commands/cluster_get_shard_version_cmd.cpp
index 8477c1140cd..5280fdb44c3 100644
--- a/src/mongo/s/commands/cluster_get_shard_version_cmd.cpp
+++ b/src/mongo/s/commands/cluster_get_shard_version_cmd.cpp
@@ -45,7 +45,7 @@ namespace {
class GetShardVersion : public Command {
public:
- GetShardVersion() : Command("getShardVersion", false, "getshardversion") {}
+ GetShardVersion() : Command("getShardVersion", "getshardversion") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_is_master_cmd.cpp b/src/mongo/s/commands/cluster_is_master_cmd.cpp
index ddb9d1c7844..afda930a308 100644
--- a/src/mongo/s/commands/cluster_is_master_cmd.cpp
+++ b/src/mongo/s/commands/cluster_is_master_cmd.cpp
@@ -46,7 +46,7 @@ namespace {
class CmdIsMaster : public Command {
public:
- CmdIsMaster() : Command("isMaster", false, "ismaster") {}
+ CmdIsMaster() : Command("isMaster", "ismaster") {}
virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
diff --git a/src/mongo/s/commands/cluster_list_databases_cmd.cpp b/src/mongo/s/commands/cluster_list_databases_cmd.cpp
index 3e9d2ecddcd..e856bad19b3 100644
--- a/src/mongo/s/commands/cluster_list_databases_cmd.cpp
+++ b/src/mongo/s/commands/cluster_list_databases_cmd.cpp
@@ -52,7 +52,7 @@ namespace {
class ListDatabasesCmd : public Command {
public:
- ListDatabasesCmd() : Command("listDatabases", true, "listdatabases") {}
+ ListDatabasesCmd() : Command("listDatabases", "listdatabases") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_list_shards_cmd.cpp b/src/mongo/s/commands/cluster_list_shards_cmd.cpp
index 2d5759acea3..0487aefdf7f 100644
--- a/src/mongo/s/commands/cluster_list_shards_cmd.cpp
+++ b/src/mongo/s/commands/cluster_list_shards_cmd.cpp
@@ -41,7 +41,7 @@ namespace {
class ListShardsCmd : public Command {
public:
- ListShardsCmd() : Command("listShards", false, "listshards") {}
+ ListShardsCmd() : Command("listShards", "listshards") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_map_reduce_cmd.cpp b/src/mongo/s/commands/cluster_map_reduce_cmd.cpp
index b424ddc6f42..8a7ab425ae1 100644
--- a/src/mongo/s/commands/cluster_map_reduce_cmd.cpp
+++ b/src/mongo/s/commands/cluster_map_reduce_cmd.cpp
@@ -148,7 +148,7 @@ BSONObj fixForShards(const BSONObj& orig,
*/
class MRCmd : public Command {
public:
- MRCmd() : Command("mapReduce", false, "mapreduce") {}
+ MRCmd() : Command("mapReduce", "mapreduce") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_move_chunk_cmd.cpp b/src/mongo/s/commands/cluster_move_chunk_cmd.cpp
index 624d5ff22e0..6b289532d86 100644
--- a/src/mongo/s/commands/cluster_move_chunk_cmd.cpp
+++ b/src/mongo/s/commands/cluster_move_chunk_cmd.cpp
@@ -57,7 +57,7 @@ namespace {
class MoveChunkCmd : public Command {
public:
- MoveChunkCmd() : Command("moveChunk", false, "movechunk") {}
+ MoveChunkCmd() : Command("moveChunk", "movechunk") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_move_primary_cmd.cpp b/src/mongo/s/commands/cluster_move_primary_cmd.cpp
index 49d167c09d2..aeafb592e7b 100644
--- a/src/mongo/s/commands/cluster_move_primary_cmd.cpp
+++ b/src/mongo/s/commands/cluster_move_primary_cmd.cpp
@@ -62,7 +62,7 @@ namespace {
class MoveDatabasePrimaryCommand : public Command {
public:
- MoveDatabasePrimaryCommand() : Command("movePrimary", false, "moveprimary") {}
+ MoveDatabasePrimaryCommand() : Command("movePrimary", "moveprimary") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_netstat_cmd.cpp b/src/mongo/s/commands/cluster_netstat_cmd.cpp
index be78b5b153a..cffd4605833 100644
--- a/src/mongo/s/commands/cluster_netstat_cmd.cpp
+++ b/src/mongo/s/commands/cluster_netstat_cmd.cpp
@@ -38,7 +38,7 @@ namespace {
class NetStatCmd : public Command {
public:
- NetStatCmd() : Command("netstat", false, "netstat") {}
+ NetStatCmd() : Command("netstat") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_pipeline_cmd.cpp b/src/mongo/s/commands/cluster_pipeline_cmd.cpp
index 010bed8f14b..25bee7dc634 100644
--- a/src/mongo/s/commands/cluster_pipeline_cmd.cpp
+++ b/src/mongo/s/commands/cluster_pipeline_cmd.cpp
@@ -40,7 +40,7 @@ namespace {
class ClusterPipelineCommand : public Command {
public:
- ClusterPipelineCommand() : Command("aggregate", false) {}
+ ClusterPipelineCommand() : Command("aggregate") {}
void help(std::stringstream& help) const {
help << "Runs the sharded aggregation command. See "
diff --git a/src/mongo/s/commands/cluster_profile_cmd.cpp b/src/mongo/s/commands/cluster_profile_cmd.cpp
index 441411149a0..5b4197062e8 100644
--- a/src/mongo/s/commands/cluster_profile_cmd.cpp
+++ b/src/mongo/s/commands/cluster_profile_cmd.cpp
@@ -35,7 +35,7 @@ namespace {
class ProfileCmd : public Command {
public:
- ProfileCmd() : Command("profile", false) {}
+ ProfileCmd() : Command("profile") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_remove_shard_cmd.cpp b/src/mongo/s/commands/cluster_remove_shard_cmd.cpp
index 27d95b6210d..c3f819856e9 100644
--- a/src/mongo/s/commands/cluster_remove_shard_cmd.cpp
+++ b/src/mongo/s/commands/cluster_remove_shard_cmd.cpp
@@ -52,7 +52,7 @@ namespace {
class RemoveShardCmd : public Command {
public:
- RemoveShardCmd() : Command("removeShard", false, "removeshard") {}
+ RemoveShardCmd() : Command("removeShard", "removeshard") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_remove_shard_from_zone_cmd.cpp b/src/mongo/s/commands/cluster_remove_shard_from_zone_cmd.cpp
index c9d808de67a..cfd072b88ef 100644
--- a/src/mongo/s/commands/cluster_remove_shard_from_zone_cmd.cpp
+++ b/src/mongo/s/commands/cluster_remove_shard_from_zone_cmd.cpp
@@ -67,7 +67,7 @@ const WriteConcernOptions kMajorityWriteConcern(WriteConcernOptions::kMajority,
*/
class RemoveShardFromZoneCmd : public Command {
public:
- RemoveShardFromZoneCmd() : Command("removeShardFromZone", false, "removeshardfromzone") {}
+ RemoveShardFromZoneCmd() : Command("removeShardFromZone", "removeshardfromzone") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/cluster_reset_error_cmd.cpp b/src/mongo/s/commands/cluster_reset_error_cmd.cpp
index e1d6b3db600..e013c474e7e 100644
--- a/src/mongo/s/commands/cluster_reset_error_cmd.cpp
+++ b/src/mongo/s/commands/cluster_reset_error_cmd.cpp
@@ -42,7 +42,7 @@ namespace {
class CmdShardingResetError : public Command {
public:
- CmdShardingResetError() : Command("resetError", false, "reseterror") {}
+ CmdShardingResetError() : Command("resetError", "reseterror") {}
virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
diff --git a/src/mongo/s/commands/cluster_shard_collection_cmd.cpp b/src/mongo/s/commands/cluster_shard_collection_cmd.cpp
index 166bddcfd77..a4f7519f176 100644
--- a/src/mongo/s/commands/cluster_shard_collection_cmd.cpp
+++ b/src/mongo/s/commands/cluster_shard_collection_cmd.cpp
@@ -121,7 +121,7 @@ BSONObj makeCreateIndexesCmd(const NamespaceString& nss,
class ShardCollectionCmd : public Command {
public:
- ShardCollectionCmd() : Command("shardCollection", false, "shardcollection") {}
+ ShardCollectionCmd() : Command("shardCollection", "shardcollection") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_split_cmd.cpp b/src/mongo/s/commands/cluster_split_cmd.cpp
index 5715e750dc4..01f2b8430e3 100644
--- a/src/mongo/s/commands/cluster_split_cmd.cpp
+++ b/src/mongo/s/commands/cluster_split_cmd.cpp
@@ -86,7 +86,7 @@ BSONObj selectMedianKey(OperationContext* opCtx,
class SplitCollectionCmd : public Command {
public:
- SplitCollectionCmd() : Command("split", false, "split") {}
+ SplitCollectionCmd() : Command("split", "split") {}
bool slaveOk() const override {
return true;
diff --git a/src/mongo/s/commands/cluster_update_zone_key_range_cmd.cpp b/src/mongo/s/commands/cluster_update_zone_key_range_cmd.cpp
index 2e48230bfe6..56647dff7ef 100644
--- a/src/mongo/s/commands/cluster_update_zone_key_range_cmd.cpp
+++ b/src/mongo/s/commands/cluster_update_zone_key_range_cmd.cpp
@@ -70,7 +70,7 @@ const WriteConcernOptions kMajorityWriteConcern(WriteConcernOptions::kMajority,
*/
class UpdateZoneKeyRangeCmd : public Command {
public:
- UpdateZoneKeyRangeCmd() : Command("updateZoneKeyRange", false, "updatezonekeyRange") {}
+ UpdateZoneKeyRangeCmd() : Command("updateZoneKeyRange", "updatezonekeyRange") {}
virtual bool slaveOk() const {
return true;
diff --git a/src/mongo/s/commands/commands_public.cpp b/src/mongo/s/commands/commands_public.cpp
index 80fbf479a93..f9b72616638 100644
--- a/src/mongo/s/commands/commands_public.cpp
+++ b/src/mongo/s/commands/commands_public.cpp
@@ -148,7 +148,7 @@ StatusWith<BSONObj> getCollation(const BSONObj& cmdObj) {
class PublicGridCommand : public Command {
protected:
- PublicGridCommand(const char* n, const char* oldname = NULL) : Command(n, false, oldname) {}
+ PublicGridCommand(const char* n, const char* oldname = NULL) : Command(n, oldname) {}
virtual bool slaveOk() const {
return true;
@@ -199,7 +199,7 @@ protected:
const char* oldname = NULL,
bool implicitCreateDb = false,
bool appendShardVersion = true)
- : Command(name, false, oldname),
+ : Command(name, oldname),
_implicitCreateDb(implicitCreateDb),
_appendShardVersion(appendShardVersion) {}