diff options
author | Will Buerger <will.buerger@mongodb.com> | 2023-05-03 18:58:03 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2023-05-03 20:09:50 +0000 |
commit | dffa373f8558c13b52299b187a261a7593189237 (patch) | |
tree | 57807b5ee3deebc29b4128b90230aa66ecc4f00f /src/mongo/s/query/cluster_aggregation_planner.cpp | |
parent | 01e26506a0981b4141bc65c9d016666ada60319e (diff) | |
download | mongo-dffa373f8558c13b52299b187a261a7593189237.tar.gz |
SERVER-76781: Decouple opdebug metric collection from telemetry
Diffstat (limited to 'src/mongo/s/query/cluster_aggregation_planner.cpp')
-rw-r--r-- | src/mongo/s/query/cluster_aggregation_planner.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mongo/s/query/cluster_aggregation_planner.cpp b/src/mongo/s/query/cluster_aggregation_planner.cpp index e10721b2915..aab9d729ae7 100644 --- a/src/mongo/s/query/cluster_aggregation_planner.cpp +++ b/src/mongo/s/query/cluster_aggregation_planner.cpp @@ -365,10 +365,11 @@ BSONObj establishMergingMongosCursor(OperationContext* opCtx, opDebug.nShards = std::max(opDebug.nShards, nShards); opDebug.cursorExhausted = exhausted; opDebug.additiveMetrics.nBatches = 1; + CurOp::get(opCtx)->setEndOfOpMetrics(responseBuilder.numDocs()); if (exhausted) { - collectTelemetryMongos(opCtx, ccc->getOriginatingCommand(), responseBuilder.numDocs()); + collectTelemetryMongos(opCtx, ccc->getOriginatingCommand()); } else { - collectTelemetryMongos(opCtx, ccc, responseBuilder.numDocs()); + collectTelemetryMongos(opCtx, ccc); } ccc->detachFromOperationContext(); |