diff options
author | Andy Schwerin <schwerin@mongodb.com> | 2015-03-26 18:45:22 -0400 |
---|---|---|
committer | Andy Schwerin <schwerin@mongodb.com> | 2015-04-06 10:16:23 -0400 |
commit | 90b7f774b818a1038cc525a9fca14207d8d5ff71 (patch) | |
tree | 604285e3d69ef379626ddd8f0a57068c287ea2ef /src/mongo/s/d_migrate.cpp | |
parent | 387e39a07522aec114a64146871eab2e015d7444 (diff) | |
download | mongo-90b7f774b818a1038cc525a9fca14207d8d5ff71.tar.gz |
SERVER-17817 Move replication-specific data from Client into ReplClientInfo decoration.
Diffstat (limited to 'src/mongo/s/d_migrate.cpp')
-rw-r--r-- | src/mongo/s/d_migrate.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/mongo/s/d_migrate.cpp b/src/mongo/s/d_migrate.cpp index 77482a082fd..a9a3d2b2571 100644 --- a/src/mongo/s/d_migrate.cpp +++ b/src/mongo/s/d_migrate.cpp @@ -70,6 +70,7 @@ #include "mongo/db/query/internal_plans.h" #include "mongo/db/query/query_knobs.h" #include "mongo/db/range_deleter_service.h" +#include "mongo/db/repl/repl_client_info.h" #include "mongo/db/repl/replication_coordinator_global.h" #include "mongo/db/storage/mmap_v1/dur.h" #include "mongo/db/write_concern.h" @@ -2200,7 +2201,8 @@ namespace mongo { repl::ReplicationCoordinator::StatusAndDuration replStatus = repl::getGlobalReplicationCoordinator()->awaitReplication( txn, - txn->getClient()->getLastOp(), + repl::ReplClientInfo::forClient( + txn->getClient()).getLastOp(), writeConcern); if (replStatus.status.code() == ErrorCodes::ExceededTimeLimit) { warning() << "secondaryThrottle on, but doc insert timed out; " @@ -2221,7 +2223,8 @@ namespace mongo { } // if running on a replicated system, we'll need to flush the docs we cloned to the secondaries - OpTime lastOpApplied = txn->getClient()->getLastOp(); + + OpTime lastOpApplied = repl::ReplClientInfo::forClient(txn->getClient()).getLastOp(); { // 4. do bulk of mods @@ -2436,7 +2439,7 @@ namespace mongo { false /* god */, true /* fromMigrate */); - *lastOpApplied = txn->getClient()->getLastOp(); + *lastOpApplied = repl::ReplClientInfo::forClient(txn->getClient()).getLastOp(); didAnything = true; } } @@ -2472,7 +2475,7 @@ namespace mongo { // We are in write lock here, so sure we aren't killing Helpers::upsert( txn, ns , updatedDoc , true ); - *lastOpApplied = txn->getClient()->getLastOp(); + *lastOpApplied = repl::ReplClientInfo::forClient(txn->getClient()).getLastOp(); didAnything = true; } } |