summaryrefslogtreecommitdiff
path: root/src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp')
-rw-r--r--src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp b/src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp
index dbfd5d1a3ef..a9b18cf3f61 100644
--- a/src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp
+++ b/src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp
@@ -75,8 +75,14 @@ public:
opCtx->setAlwaysInterruptAtStepDownOrUp();
- bool fromMigrate = request().getFromMigrate().value_or(false);
- DropCollectionCoordinator::dropCollectionLocally(opCtx, ns(), fromMigrate);
+ try {
+ DropCollectionCoordinator::dropCollectionLocally(opCtx, ns());
+ } catch (const ExceptionFor<ErrorCodes::NamespaceNotFound>&) {
+ LOGV2_DEBUG(5280920,
+ 1,
+ "Namespace not found while trying to delete local collection",
+ "namespace"_attr = ns());
+ }
// The txnParticipant will only be missing when the command was sent from a coordinator
// running an old 5.0.0 binary that didn't attach a sessionId & txnNumber.