diff options
author | Randolph Tan <randolph@10gen.com> | 2014-10-10 14:11:52 -0400 |
---|---|---|
committer | Randolph Tan <randolph@10gen.com> | 2014-10-15 11:55:42 -0400 |
commit | 658f0bce4379fc0334a53c4381d57b8b7c7d53b7 (patch) | |
tree | 57b9bf3f7d1aa4be39856b0214599c6e0a967bfb /src/mongo/db/commands/cleanup_orphaned_cmd.cpp | |
parent | 3d7564c44a2117c72b9c6830c5a14ab467f8ffa3 (diff) | |
download | mongo-658f0bce4379fc0334a53c4381d57b8b7c7d53b7.tar.gz |
SERVER-15591 enforce secondaryThrottle during moveChunk commit
Diffstat (limited to 'src/mongo/db/commands/cleanup_orphaned_cmd.cpp')
-rw-r--r-- | src/mongo/db/commands/cleanup_orphaned_cmd.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/mongo/db/commands/cleanup_orphaned_cmd.cpp b/src/mongo/db/commands/cleanup_orphaned_cmd.cpp index fe468c0b166..96093bdeca1 100644 --- a/src/mongo/db/commands/cleanup_orphaned_cmd.cpp +++ b/src/mongo/db/commands/cleanup_orphaned_cmd.cpp @@ -248,6 +248,15 @@ namespace mongo { repl::ReplicationCoordinator* replCoordinator = repl::getGlobalReplicationCoordinator(); Status status = replCoordinator->checkIfWriteConcernCanBeSatisfied(writeConcern); + + if (replCoordinator->getReplicationMode() == + repl::ReplicationCoordinator::modeMasterSlave && + writeConcern.shouldWaitForOtherNodes()) { + warning() << "cleanupOrphaned cannot check if write concern setting " + << writeConcern.toBSON() + << " can be enforced in a master slave configuration"; + } + if (!status.isOK() && status != ErrorCodes::NoReplicationEnabled) { return appendCommandStatus(result, status); } |