summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mongo/db/s/sharding_server_status.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/db/s/sharding_server_status.cpp b/src/mongo/db/s/sharding_server_status.cpp
index 618e828bec2..16716a5fb68 100644
--- a/src/mongo/db/s/sharding_server_status.cpp
+++ b/src/mongo/db/s/sharding_server_status.cpp
@@ -146,7 +146,7 @@ public:
// `config.collections` collection. This count must only be appended when serverStatus is
// invoked on the config server.
if (serverGlobalParams.clusterRole == ClusterRole::ConfigServer) {
- AutoGetCollectionForRead autoColl(opCtx, CollectionType::ConfigNS);
+ AutoGetCollectionForReadLockFree autoColl(opCtx, CollectionType::ConfigNS);
const auto& collection = autoColl.getCollection();
const auto numShardedCollections = collection ? collection->numRecords(opCtx) : 0;
result.append("numShardedCollections", numShardedCollections);