summaryrefslogtreecommitdiff
path: root/src/mongo/executor
diff options
context:
space:
mode:
authorCheahuychou Mao <cheahuychou.mao@mongodb.com>2020-03-27 02:27:49 -0400
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-03-30 01:48:39 +0000
commitffff3f7fce95d45192c8b6cb65845907d6128922 (patch)
tree095a616312119e6724c10a2e56a27ecadd92b79c /src/mongo/executor
parentd8acf3c44e41fd4423caf8a337264a6dac86b8c5 (diff)
downloadmongo-ffff3f7fce95d45192c8b6cb65845907d6128922.tar.gz
SERVER-47167 Make hedged read tests more robust
Diffstat (limited to 'src/mongo/executor')
-rw-r--r--src/mongo/executor/network_interface_tl.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/executor/network_interface_tl.cpp b/src/mongo/executor/network_interface_tl.cpp
index 3f2f6871c3d..a988ef76420 100644
--- a/src/mongo/executor/network_interface_tl.cpp
+++ b/src/mongo/executor/network_interface_tl.cpp
@@ -420,7 +420,8 @@ Status NetworkInterfaceTL::startCommand(const TaskExecutor::CallbackHandle& cbHa
}
bool targetHostsInAlphabeticalOrder =
- MONGO_unlikely(networkInterfaceSendRequestsToTargetHostsInAlphabeticalOrder.shouldFail());
+ MONGO_unlikely(networkInterfaceSendRequestsToTargetHostsInAlphabeticalOrder.shouldFail(
+ [request](const BSONObj&) { return request.hedgeOptions != boost::none; }));
if (targetHostsInAlphabeticalOrder) {
// Sort the target hosts by host names.