summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSpencer T Brody <spencer@mongodb.com>2014-11-20 16:43:57 -0500
committerSpencer T Brody <spencer@mongodb.com>2014-11-20 17:01:05 -0500
commit5d1f0d27992da53eb1c546f413e5b34e78d8c439 (patch)
tree623a33cea2d47d9a6f9834a277b5c31624621647
parent5d53a26ce33320b5b91ff5a8fcd2b69be1367367 (diff)
downloadmongo-5d1f0d27992da53eb1c546f413e5b34e78d8c439.tar.gz
SERVER-15997 Register the ReplicationCoordinatorImpl as a killop listener
-rw-r--r--src/mongo/db/db.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mongo/db/db.cpp b/src/mongo/db/db.cpp
index 482bb0f716d..34d915bced6 100644
--- a/src/mongo/db/db.cpp
+++ b/src/mongo/db/db.cpp
@@ -775,12 +775,14 @@ MONGO_INITIALIZER_GENERAL(CreateAuthorizationManager,
MONGO_INITIALIZER_WITH_PREREQUISITES(CreateReplicationManager, ("SetGlobalEnvironment"))
(InitializerContext* context) {
- repl::setGlobalReplicationCoordinator(new repl::ReplicationCoordinatorImpl(
+ repl::ReplicationCoordinatorImpl* replCoord = new repl::ReplicationCoordinatorImpl(
getGlobalReplSettings(),
new repl::ReplicationCoordinatorExternalStateImpl,
new repl::NetworkInterfaceImpl,
new repl::TopologyCoordinatorImpl(Seconds(repl::maxSyncSourceLagSecs)),
- static_cast<int64_t>(curTimeMillis64())));
+ static_cast<int64_t>(curTimeMillis64()));
+ repl::setGlobalReplicationCoordinator(replCoord);
+ getGlobalEnvironment()->registerKillOpListener(replCoord);
return Status::OK();
}