summaryrefslogtreecommitdiff
path: root/src/mongo/s
diff options
context:
space:
mode:
authorDianna Hohensee <dianna.hohensee@10gen.com>2016-01-06 18:06:16 -0500
committerDianna Hohensee <dianna.hohensee@10gen.com>2016-01-15 15:23:14 -0500
commit2d8008289b9d075c56841dc08830bb7cff28aeaf (patch)
tree4b382af4f4f65765f55661b9a54a62f988e3a494 /src/mongo/s
parent64a7daba1746dcda0f7d25eab82d35e2c093d54f (diff)
downloadmongo-2d8008289b9d075c56841dc08830bb7cff28aeaf.tar.gz
SERVER-22057 refactor OpObserver::onUpdate and MigrationSourceManager::logUpdateOp to directly take the updated document
Diffstat (limited to 'src/mongo/s')
-rw-r--r--src/mongo/s/d_migrate.cpp4
-rw-r--r--src/mongo/s/d_state.h4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/s/d_migrate.cpp b/src/mongo/s/d_migrate.cpp
index 5fb8c038a5a..a5ba7abd118 100644
--- a/src/mongo/s/d_migrate.cpp
+++ b/src/mongo/s/d_migrate.cpp
@@ -441,11 +441,11 @@ void logInsertOpForSharding(OperationContext* txn,
void logUpdateOpForSharding(OperationContext* txn,
const char* ns,
- const BSONObj& pattern,
+ const BSONObj& updatedDoc,
bool notInActiveChunk) {
ShardingState* shardingState = ShardingState::get(txn);
if (shardingState->enabled())
- shardingState->migrationSourceManager()->logUpdateOp(txn, ns, pattern, notInActiveChunk);
+ shardingState->migrationSourceManager()->logUpdateOp(txn, ns, updatedDoc, notInActiveChunk);
}
void logDeleteOpForSharding(OperationContext* txn,
diff --git a/src/mongo/s/d_state.h b/src/mongo/s/d_state.h
index 7ab53dd5741..a83e74f01e8 100644
--- a/src/mongo/s/d_state.h
+++ b/src/mongo/s/d_state.h
@@ -79,14 +79,14 @@ void logInsertOpForSharding(OperationContext* txn,
* to determine whether the update should be logged to the migration transfer mods log.
*
* 'ns' name of the collection in which the operation will occur.
- * 'pattern' contains the _id value of the doc being updated.
+ * 'updatedDoc' updated document.
* 'notInActiveChunk' if true indicates that the update is coming from a donor shard
* in a current chunk migration, and so does not need to be entered in this shard's
* outgoing transfer log.
*/
void logUpdateOpForSharding(OperationContext* txn,
const char* ns,
- const BSONObj& pattern,
+ const BSONObj& updatedDoc,
bool notInActiveChunk);
/**