summaryrefslogtreecommitdiff
path: root/src/mongo/s/commands/cluster_is_master_cmd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/s/commands/cluster_is_master_cmd.cpp')
-rw-r--r--src/mongo/s/commands/cluster_is_master_cmd.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mongo/s/commands/cluster_is_master_cmd.cpp b/src/mongo/s/commands/cluster_is_master_cmd.cpp
index 566660ea92d..761aca9bba1 100644
--- a/src/mongo/s/commands/cluster_is_master_cmd.cpp
+++ b/src/mongo/s/commands/cluster_is_master_cmd.cpp
@@ -67,14 +67,14 @@ public:
// No auth required
}
- virtual bool run(OperationContext* txn,
+ virtual bool run(OperationContext* opCtx,
const std::string& dbname,
BSONObj& cmdObj,
int options,
std::string& errmsg,
BSONObjBuilder& result) {
- auto& clientMetadataIsMasterState = ClientMetadataIsMasterState::get(txn->getClient());
+ auto& clientMetadataIsMasterState = ClientMetadataIsMasterState::get(opCtx->getClient());
bool seenIsMaster = clientMetadataIsMasterState.hasSeenIsMaster();
if (!seenIsMaster) {
clientMetadataIsMasterState.setSeenIsMaster();
@@ -97,10 +97,10 @@ public:
invariant(swParseClientMetadata.getValue());
- swParseClientMetadata.getValue().get().logClientMetadata(txn->getClient());
+ swParseClientMetadata.getValue().get().logClientMetadata(opCtx->getClient());
clientMetadataIsMasterState.setClientMetadata(
- txn->getClient(), std::move(swParseClientMetadata.getValue()));
+ opCtx->getClient(), std::move(swParseClientMetadata.getValue()));
}
result.appendBool("ismaster", true);
@@ -119,9 +119,9 @@ public:
"automationServiceDescriptor",
static_cast<ServerParameter*>(nullptr));
if (parameter)
- parameter->append(txn, result, "automationServiceDescriptor");
+ parameter->append(opCtx, result, "automationServiceDescriptor");
- MessageCompressorManager::forSession(txn->getClient()->session())
+ MessageCompressorManager::forSession(opCtx->getClient()->session())
.serverNegotiate(cmdObj, &result);
return true;