summaryrefslogtreecommitdiff
path: root/src/mongo
diff options
context:
space:
mode:
authorjannaerin <golden.janna@gmail.com>2018-01-29 18:16:03 -0500
committerjannaerin <golden.janna@gmail.com>2018-01-31 10:37:27 -0500
commit8099a4510021912ac769de6dacd3ec8dc74d896c (patch)
tree791e8cbbb1263f9f6de1e202ad431d2ab0ee635d /src/mongo
parent28c18ba63785d6cbf0ae27c4d5031255b6b79b2c (diff)
downloadmongo-8099a4510021912ac769de6dacd3ec8dc74d896c.tar.gz
SERVER-29771 Remove the forceerror command
Diffstat (limited to 'src/mongo')
-rw-r--r--src/mongo/db/commands/generic.cpp25
1 files changed, 0 insertions, 25 deletions
diff --git a/src/mongo/db/commands/generic.cpp b/src/mongo/db/commands/generic.cpp
index d5bd5b0da1e..28394239931 100644
--- a/src/mongo/db/commands/generic.cpp
+++ b/src/mongo/db/commands/generic.cpp
@@ -297,31 +297,6 @@ public:
} listCommandsCmd;
-/* for testing purposes only */
-class CmdForceError : public BasicCommand {
-public:
- std::string help() const override {
- return "for testing purposes only. forces a user assertion exception";
- }
- virtual bool slaveOk() const {
- return true;
- }
- virtual bool supportsWriteConcern(const BSONObj& cmd) const override {
- return false;
- }
- virtual void addRequiredPrivileges(const std::string& dbname,
- const BSONObj& cmdObj,
- std::vector<Privilege>* out) {} // No auth required
- CmdForceError() : BasicCommand("forceerror") {}
- bool run(OperationContext* opCtx,
- const string& dbnamne,
- const BSONObj& cmdObj,
- BSONObjBuilder& result) {
- LastError::get(cc()).setLastError(10038, "forced error");
- return false;
- }
-} cmdForceError;
-
class GetLogCmd : public ErrmsgCommandDeprecated {
public:
GetLogCmd() : ErrmsgCommandDeprecated("getLog") {}