diff options
author | Billy Donahue <billy.donahue@mongodb.com> | 2019-09-10 19:03:36 +0000 |
---|---|---|
committer | evergreen <evergreen@mongodb.com> | 2019-09-10 19:03:36 +0000 |
commit | 5a0f718e1309a4484580d8038016d043ef3b887f (patch) | |
tree | 7a331d57ba6e33e61f96ed69b2aa387003a039ab /src/mongo/s/query/cluster_aggregate.cpp | |
parent | b9e29cd56ebc9aca06f68eeeda7c523d3dfd6d41 (diff) | |
download | mongo-5a0f718e1309a4484580d8038016d043ef3b887f.tar.gz |
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.
Diffstat (limited to 'src/mongo/s/query/cluster_aggregate.cpp')
-rw-r--r-- | src/mongo/s/query/cluster_aggregate.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/s/query/cluster_aggregate.cpp b/src/mongo/s/query/cluster_aggregate.cpp index cfc60541fb3..953f4c48d05 100644 --- a/src/mongo/s/query/cluster_aggregate.cpp +++ b/src/mongo/s/query/cluster_aggregate.cpp @@ -147,7 +147,7 @@ sharded_agg_helpers::DispatchShardPipelineResults dispatchExchangeConsumerPipeli invariant(!litePipe.hasChangeStream()); auto opCtx = expCtx->opCtx; - if (MONGO_FAIL_POINT(clusterAggregateFailToDispatchExchangeConsumerPipeline)) { + if (MONGO_unlikely(clusterAggregateFailToDispatchExchangeConsumerPipeline.shouldFail())) { log() << "clusterAggregateFailToDispatchExchangeConsumerPipeline fail point enabled."; uasserted(ErrorCodes::FailPointEnabled, "Asserting on exhange consumer pipeline dispatch due to failpoint."); @@ -300,7 +300,7 @@ AsyncRequestsSender::Response establishMergingShardCursor(OperationContext* opCt const AggregationRequest& request, const BSONObj mergeCmdObj, const ShardId& mergingShardId) { - if (MONGO_FAIL_POINT(clusterAggregateFailToEstablishMergingShardCursor)) { + if (MONGO_unlikely(clusterAggregateFailToEstablishMergingShardCursor.shouldFail())) { log() << "clusterAggregateFailToEstablishMergingShardCursor fail point enabled."; uasserted(ErrorCodes::FailPointEnabled, "Asserting on establishing merging shard cursor due to failpoint."); |