summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEliot Horowitz <eliot@10gen.com>2013-06-24 15:03:46 -0400
committerDan Pasette <dan@10gen.com>2013-08-01 20:31:28 -0400
commite0ae2fd180827aeafe69644f66478459d026b30a (patch)
treef00719d1525ed659c11c522077df8dd26e1696ca
parent343e5c12c9cdbac66a2225fd4d49f884971df378 (diff)
downloadmongo-e0ae2fd180827aeafe69644f66478459d026b30a.tar.gz
SERVER-9699: remove clean command
Conflicts: src/mongo/db/dbcommands_admin.cpp
-rw-r--r--src/mongo/db/dbcommands_admin.cpp37
1 files changed, 0 insertions, 37 deletions
diff --git a/src/mongo/db/dbcommands_admin.cpp b/src/mongo/db/dbcommands_admin.cpp
index 7ab769a9988..623a397201c 100644
--- a/src/mongo/db/dbcommands_admin.cpp
+++ b/src/mongo/db/dbcommands_admin.cpp
@@ -52,43 +52,6 @@
namespace mongo {
- class CleanCmd : public Command {
- public:
- CleanCmd() : Command( "clean" ) {}
-
- virtual bool slaveOk() const { return true; }
- virtual LockType locktype() const { return WRITE; }
-
- virtual void help(stringstream& h) const { h << "internal"; }
- virtual void addRequiredPrivileges(const std::string& dbname,
- const BSONObj& cmdObj,
- std::vector<Privilege>* out) {
- ActionSet actions;
- actions.addAction(ActionType::clean);
- out->push_back(Privilege(parseNs(dbname, cmdObj), actions));
- }
- bool run(const string& dbname, BSONObj& cmdObj, int, string& errmsg, BSONObjBuilder& result, bool fromRepl ) {
- string dropns = dbname + "." + cmdObj.firstElement().valuestrsafe();
-
- if ( !cmdLine.quiet )
- tlog() << "CMD: clean " << dropns << endl;
-
- NamespaceDetails *d = nsdetails(dropns);
-
- if ( ! d ) {
- errmsg = "ns not found";
- return 0;
- }
-
- for ( int i = 0; i < Buckets; i++ )
- d->deletedList[i].Null();
-
- result.append("ns", dropns.c_str());
- return 1;
- }
-
- } cleanCmd;
-
namespace dur {
boost::filesystem::path getJournalDir();
}