summaryrefslogtreecommitdiff
path: root/src/mongo/db/ttl.cpp
diff options
context:
space:
mode:
authorHaley Connelly <haley.connelly@mongodb.com>2020-08-10 21:14:01 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-08-12 17:32:14 +0000
commitb018ba7b5bfeea26b1df08fc8bf78e9665718e92 (patch)
tree9721aa193aaafdcf51dfc0efe7462c60a3d3113f /src/mongo/db/ttl.cpp
parent6bda102aac85358738328fc5eb5d85d2e19acf44 (diff)
downloadmongo-b018ba7b5bfeea26b1df08fc8bf78e9665718e92.tar.gz
SERVER-49914 Disable the TTL monitor for <database>.system.resharding.* namespaces
Diffstat (limited to 'src/mongo/db/ttl.cpp')
-rw-r--r--src/mongo/db/ttl.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mongo/db/ttl.cpp b/src/mongo/db/ttl.cpp
index dfdd2f4aaa4..18e124c9b68 100644
--- a/src/mongo/db/ttl.cpp
+++ b/src/mongo/db/ttl.cpp
@@ -206,6 +206,12 @@ private:
continue;
}
+ if (nss->isTemporaryReshardingCollection()) {
+ // For resharding, the donor shard primary is responsible for performing the TTL
+ // deletions.
+ continue;
+ }
+
AutoGetCollection autoColl(&opCtx, *nss, MODE_IS);
Collection* coll = autoColl.getCollection();
// The collection with `uuid` might be renamed before the lock and the wrong