diff options
author | Pierlauro Sciarelli <pierlauro.sciarelli@mongodb.com> | 2020-06-15 14:13:06 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-06-15 15:45:46 +0000 |
commit | f84654bc3cf814ae75b8454bcf52bc2929ec53ea (patch) | |
tree | f70ecb4ff8bc3f0012e10d83f5692435edaa12d5 /src/mongo/db/s/shard_filtering_metadata_refresh.cpp | |
parent | 6b4b5a25da750ba0a8c8eef288806bf4fd775a8f (diff) | |
download | mongo-f84654bc3cf814ae75b8454bcf52bc2929ec53ea.tar.gz |
SERVER-48783 Critical section should not be entered when performing a shard version recovery
Diffstat (limited to 'src/mongo/db/s/shard_filtering_metadata_refresh.cpp')
-rw-r--r-- | src/mongo/db/s/shard_filtering_metadata_refresh.cpp | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/src/mongo/db/s/shard_filtering_metadata_refresh.cpp b/src/mongo/db/s/shard_filtering_metadata_refresh.cpp index 47e5a3835f1..18e1b8da13b 100644 --- a/src/mongo/db/s/shard_filtering_metadata_refresh.cpp +++ b/src/mongo/db/s/shard_filtering_metadata_refresh.cpp @@ -102,9 +102,6 @@ SharedSemiFuture<void> recoverRefreshShardVersion(ServiceContext* serviceContext auto* const csr = CollectionShardingRuntime::get(opCtx.get(), nss); auto csrLock = CollectionShardingRuntime::CSRLock::lockExclusive(opCtx.get(), csr); csr->resetShardVersionRecoverRefreshFuture(csrLock); - if (runRecover) { - csr->exitCriticalSection(opCtx.get()); - } }); if (runRecover) { @@ -194,11 +191,6 @@ void onShardVersionMismatch(OperationContext* opCtx, csr->getCriticalSectionSignal(opCtx, ShardingMigrationCriticalSection::kWrite); if (!inRecoverOrRefresh && !critSecSignal) { - if (runRecover) { - CollectionShardingRuntime::get(opCtx, nss) - ->enterCriticalSectionCatchUpPhase(csrLock); - } - csr->setShardVersionRecoverRefreshFuture( recoverRefreshShardVersion(opCtx->getServiceContext(), nss, runRecover), csrLock); |