summaryrefslogtreecommitdiff
path: root/src/mongo/db/s/shardsvr_collmod_participant_command.cpp
diff options
context:
space:
mode:
authorDaniel Gómez Ferro <daniel.gomezferro@mongodb.com>2023-01-03 14:56:58 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2023-01-03 15:57:28 +0000
commit6ec1e03c0968d786f62cad9db47408411301e7af (patch)
treec132befa4b39659a443be5d010fe9a7cb3eb70ce /src/mongo/db/s/shardsvr_collmod_participant_command.cpp
parent1f7860fb48efaf3b47ec63cd01da8b540c06a5b0 (diff)
downloadmongo-6ec1e03c0968d786f62cad9db47408411301e7af.tar.gz
SERVER-69770 Enforce lock mode in CollectionShardingRuntime API
Diffstat (limited to 'src/mongo/db/s/shardsvr_collmod_participant_command.cpp')
-rw-r--r--src/mongo/db/s/shardsvr_collmod_participant_command.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/db/s/shardsvr_collmod_participant_command.cpp b/src/mongo/db/s/shardsvr_collmod_participant_command.cpp
index b3ff0e66e22..43948caf639 100644
--- a/src/mongo/db/s/shardsvr_collmod_participant_command.cpp
+++ b/src/mongo/db/s/shardsvr_collmod_participant_command.cpp
@@ -103,8 +103,8 @@ public:
// TODO (SERVER-71444): Fix to be interruptible or document exception.
UninterruptibleLockGuard noInterrupt(opCtx->lockState()); // NOLINT.
AutoGetCollection autoColl(opCtx, bucketNs, MODE_IX);
- CollectionShardingRuntime::assertCollectionLockedAndAcquire(
- opCtx, bucketNs, CSRAcquisitionMode::kExclusive)
+ CollectionShardingRuntime::assertCollectionLockedAndAcquireExclusive(opCtx,
+ bucketNs)
->clearFilteringMetadata(opCtx);
}