diff options
author | Steve Tarzia <steve.tarzia@mongodb.com> | 2023-03-15 14:24:14 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2023-03-15 18:00:29 +0000 |
commit | ca939e3cc87615cc33211efbc097283c5f53b68b (patch) | |
tree | 24a805d50265b3dae6417b029c846827ea1eb6ba | |
parent | fb56c5b9a1d93ce4fe66238f723b554f1a13e1c3 (diff) | |
download | mongo-ca939e3cc87615cc33211efbc097283c5f53b68b.tar.gz |
SERVER-74550 Reserve 25% of time budget for processing buffered partial results
-rw-r--r-- | src/mongo/s/query/cluster_find.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/s/query/cluster_find.cpp b/src/mongo/s/query/cluster_find.cpp index ffb745e8b4a..c9f22408463 100644 --- a/src/mongo/s/query/cluster_find.cpp +++ b/src/mongo/s/query/cluster_find.cpp @@ -308,10 +308,10 @@ CursorId runQueryWithoutRetrying(OperationContext* opCtx, // deadline so that we have time to return partial results before the opCtx is killed. auto deadline = opCtx->getDeadline(); if (findCommand.getAllowPartialResults() && findCommand.getMaxTimeMS()) { - // Reserve 10% of the time budget (up to 100,000 microseconds max) for processing + // Reserve 25% of the time budget (up to 100,000 microseconds max) for processing // buffered partial results. deadline -= - Microseconds{std::min(1000LL * (*findCommand.getMaxTimeMS()) / 10, 100'000LL)}; + Microseconds{std::min(1000LL * findCommand.getMaxTimeMS().get() / 4, 100'000LL)}; LOGV2_DEBUG( 5746901, 0, |