From 5a0f718e1309a4484580d8038016d043ef3b887f Mon Sep 17 00:00:00 2001 From: Billy Donahue Date: Tue, 10 Sep 2019 19:03:36 +0000 Subject: SERVER-43119 FailPoint cleanup - Don't use MONGO_INITIALIZER to declare each fail point. We only need one init task in total: freeze and iterate the registry. - remove MONGO_FAIL_POINT_DECLARE macro (extern) - remove MONGO_FAIL_POINT_SHOULD_FAIL macro (FailPoint::shouldFail) - remove MONGO_FAIL_POINT_BLOCK_IF (FailPoint::executeIf) - remove MONGO_FAIL_POINT_BLOCK (FailPoint::execute) - clean up FailPointRegistry and fail_point_service implementation. --- src/mongo/db/s/collection_range_deleter.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mongo/db/s/collection_range_deleter.cpp') diff --git a/src/mongo/db/s/collection_range_deleter.cpp b/src/mongo/db/s/collection_range_deleter.cpp index d5affc26cc0..27b0a47a7ef 100644 --- a/src/mongo/db/s/collection_range_deleter.cpp +++ b/src/mongo/db/s/collection_range_deleter.cpp @@ -395,9 +395,9 @@ StatusWith CollectionRangeDeleter::_doDeletion(OperationContext* opCtx, PlanExecutor::YIELD_MANUAL, InternalPlanner::FORWARD); - if (MONGO_FAIL_POINT(hangBeforeDoingDeletion)) { + if (MONGO_unlikely(hangBeforeDoingDeletion.shouldFail())) { LOG(0) << "Hit hangBeforeDoingDeletion failpoint"; - MONGO_FAIL_POINT_PAUSE_WHILE_SET_OR_INTERRUPTED(opCtx, hangBeforeDoingDeletion); + hangBeforeDoingDeletion.pauseWhileSet(opCtx); } PlanYieldPolicy planYieldPolicy(exec.get(), PlanExecutor::YIELD_MANUAL); -- cgit v1.2.1