diff options
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.cpp | 13 |
1 files changed, 2 insertions, 11 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 950f2d296d7..dbfd5d1a3ef 100644 --- a/src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp +++ b/src/mongo/db/s/shardsvr_drop_collection_participant_command.cpp @@ -75,17 +75,8 @@ public: opCtx->setAlwaysInterruptAtStepDownOrUp(); - try { - bool fromMigrate = - request().getFromMigrate() ? request().getFromMigrate().value() : false; - - DropCollectionCoordinator::dropCollectionLocally(opCtx, ns(), fromMigrate); - } catch (const ExceptionFor<ErrorCodes::NamespaceNotFound>&) { - LOGV2_DEBUG(5280920, - 1, - "Namespace not found while trying to delete local collection", - "namespace"_attr = ns()); - } + bool fromMigrate = request().getFromMigrate().value_or(false); + DropCollectionCoordinator::dropCollectionLocally(opCtx, ns(), fromMigrate); // 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. |