summaryrefslogtreecommitdiff
path: root/src/mongo/db/auth/authz_session_external_state_d.cpp
diff options
context:
space:
mode:
authorNick Zolnierz <nicholas.zolnierz@mongodb.com>2018-03-02 10:44:20 -0500
committerNick Zolnierz <nicholas.zolnierz@mongodb.com>2018-03-02 10:44:20 -0500
commita8fddd07a740e959646995ef93139887b3b3eb5c (patch)
treea2365652bb2b6933c3f0d6cd56c6105bd0060b20 /src/mongo/db/auth/authz_session_external_state_d.cpp
parent1037536d24d1dc6449fe91c8be0023dc91bdf3ec (diff)
downloadmongo-a8fddd07a740e959646995ef93139887b3b3eb5c.tar.gz
Revert "SERVER-29519 Remove getGlobalReplicationCoordinator. Replace when getting decoration through service context (global if needed)."
This reverts commit 7d37a75df3f6035a7afcb51123b88f0e99308fc8.
Diffstat (limited to 'src/mongo/db/auth/authz_session_external_state_d.cpp')
-rw-r--r--src/mongo/db/auth/authz_session_external_state_d.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/mongo/db/auth/authz_session_external_state_d.cpp b/src/mongo/db/auth/authz_session_external_state_d.cpp
index 0c8689feb10..77f0f0df856 100644
--- a/src/mongo/db/auth/authz_session_external_state_d.cpp
+++ b/src/mongo/db/auth/authz_session_external_state_d.cpp
@@ -34,7 +34,7 @@
#include "mongo/db/client.h"
#include "mongo/db/jsobj.h"
#include "mongo/db/operation_context.h"
-#include "mongo/db/repl/replication_coordinator.h"
+#include "mongo/db/repl/replication_coordinator_global.h"
#include "mongo/scripting/engine.h"
#include "mongo/util/assert_util.h"
@@ -60,10 +60,9 @@ bool AuthzSessionExternalStateMongod::shouldIgnoreAuthChecks() const {
bool AuthzSessionExternalStateMongod::serverIsArbiter() const {
// Arbiters have access to extra privileges under localhost. See SERVER-5479.
- return (
- repl::ReplicationCoordinator::get(getGlobalServiceContext())->getReplicationMode() ==
- repl::ReplicationCoordinator::modeReplSet &&
- repl::ReplicationCoordinator::get(getGlobalServiceContext())->getMemberState().arbiter());
+ return (repl::getGlobalReplicationCoordinator()->getReplicationMode() ==
+ repl::ReplicationCoordinator::modeReplSet &&
+ repl::getGlobalReplicationCoordinator()->getMemberState().arbiter());
}
} // namespace mongo