summaryrefslogtreecommitdiff
path: root/src/mongo/db/s/start_chunk_clone_request.cpp
diff options
context:
space:
mode:
authorEsha Maharishi <esha.maharishi@mongodb.com>2020-05-12 17:26:45 -0400
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-05-18 04:14:45 +0000
commitd0e6f87351312a299a17f6d63e3f2f4db834ae1f (patch)
treecf758ddf2c85d414d9eab4aa1b318791934aae30 /src/mongo/db/s/start_chunk_clone_request.cpp
parent7e2111ef33fc40959a254bd3109466176ae60718 (diff)
downloadmongo-d0e6f87351312a299a17f6d63e3f2f4db834ae1f.tar.gz
SERVER-47992 Make disableResumableRangeDeleter just prevent ranges from being submitted for deletio
Diffstat (limited to 'src/mongo/db/s/start_chunk_clone_request.cpp')
-rw-r--r--src/mongo/db/s/start_chunk_clone_request.cpp21
1 files changed, 8 insertions, 13 deletions
diff --git a/src/mongo/db/s/start_chunk_clone_request.cpp b/src/mongo/db/s/start_chunk_clone_request.cpp
index e81f5754b90..86567dce161 100644
--- a/src/mongo/db/s/start_chunk_clone_request.cpp
+++ b/src/mongo/db/s/start_chunk_clone_request.cpp
@@ -152,12 +152,10 @@ StatusWith<StartChunkCloneRequest> StartChunkCloneRequest::createFromCommand(Nam
}
}
- if (obj.getField("uuid")) {
- request._migrationId = UUID::parse(obj);
- request._lsid = LogicalSessionId::parse(IDLParserErrorContext("StartChunkCloneRequest"),
- obj[kLsid].Obj());
- request._txnNumber = obj.getField(kTxnNumber).Long();
- }
+ request._migrationId = UUID::parse(obj);
+ request._lsid =
+ LogicalSessionId::parse(IDLParserErrorContext("StartChunkCloneRequest"), obj[kLsid].Obj());
+ request._txnNumber = obj.getField(kTxnNumber).Long();
return request;
}
@@ -175,19 +173,16 @@ void StartChunkCloneRequest::appendAsCommand(
const BSONObj& chunkMinKey,
const BSONObj& chunkMaxKey,
const BSONObj& shardKeyPattern,
- const MigrationSecondaryThrottleOptions& secondaryThrottle,
- bool resumableRangeDeleterDisabled) {
+ const MigrationSecondaryThrottleOptions& secondaryThrottle) {
invariant(builder->asTempObj().isEmpty());
invariant(nss.isValid());
invariant(fromShardConnectionString.isValid());
builder->append(kRecvChunkStart, nss.ns());
- if (!resumableRangeDeleterDisabled) {
- migrationId.appendToBuilder(builder, kMigrationId);
- builder->append(kLsid, lsid.toBSON());
- builder->append(kTxnNumber, txnNumber);
- }
+ migrationId.appendToBuilder(builder, kMigrationId);
+ builder->append(kLsid, lsid.toBSON());
+ builder->append(kTxnNumber, txnNumber);
sessionId.append(builder);
builder->append(kFromShardConnectionString, fromShardConnectionString.toString());