-
Type: Task
-
Resolution: Unresolved
-
Priority: Minor - P4
-
None
-
Affects Version/s: None
-
Component/s: None
-
Query Integration
-
QI 2024-05-27, QI 2024-06-10, QI 2024-06-24
While working on SERVER-87634 an issue came up with over-reporting metrics in lookup_query_stats.js. This seems to be caused by the curOp metrics block inside of collectQueryStats(). In the jstest, there are 5 tests being run, each one running a query with a different scan, and then runs explain with every verbosity. The second test's assertion for curScannedObjects fails, regardless of what order the tests are being run. Thus, to avoid over-reporting right now we collect directly with collectQueryStatsMongod instead of collectQueryStats() so that we can skip curOp->debug().setPlanSummaryMetrics() and CurOp::setEndOfOpMetrics(). To reproduce the issue, replace
collectQueryStatsMongod(opCtx, expCtx, std::move(curOp->debug().queryStatsInfo.key));
inside of _runAggregate() with
collectQueryStats(opCtx, expCtx, explainExecutor, nullptr);
compile, and then run
buildscripts/resmoke.py run --suites=aggregation jstests/aggregation/sources/lookup/lookup_query_stats.js --additionalFeatureFlags=featureFlagQueryStats
- is depended on by
-
SERVER-89053 Enable query stats metrics assertions for explain queries in sharded tests
- Blocked
- is related to
-
SERVER-87634 Add explain to agg key for query stats
- Closed