summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAllison Easton <allison.easton@mongodb.com>2021-07-20 08:55:52 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2021-07-22 10:33:25 +0000
commit550ed16f978dd43e81577c7b0e9ede3de7f68f6a (patch)
tree8fe6afedda15b319f681b1fa5a9c80958f85539c /src
parent2ee3612cf4476a17ce78c05dc1adfcc9153d716a (diff)
downloadmongo-550ed16f978dd43e81577c7b0e9ede3de7f68f6a.tar.gz
SERVER-55649 Sharding messages being logged for non-sharded clusters
Diffstat (limited to 'src')
-rw-r--r--src/mongo/db/s/metadata_manager.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mongo/db/s/metadata_manager.cpp b/src/mongo/db/s/metadata_manager.cpp
index 2c16eb5e051..1b604aa97f6 100644
--- a/src/mongo/db/s/metadata_manager.cpp
+++ b/src/mongo/db/s/metadata_manager.cpp
@@ -339,7 +339,10 @@ void MetadataManager::setFilteringMetadata(CollectionMetadata remoteMetadata) {
// Collection is becoming sharded
if (_metadata.empty()) {
- LOG(0) << "Marking collection " << _nss.ns() << " as " << remoteMetadata.toStringBasic();
+ if (remoteMetadata.isSharded()) {
+ LOG(0) << "Marking collection " << _nss.ns() << " as "
+ << remoteMetadata.toStringBasic();
+ }
invariant(_receivingChunks.empty());
invariant(_rangesToClean.isEmpty());