summaryrefslogtreecommitdiff
path: root/src/mongo/db/commands/mr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/commands/mr.cpp')
-rw-r--r--src/mongo/db/commands/mr.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mongo/db/commands/mr.cpp b/src/mongo/db/commands/mr.cpp
index d0066e7e066..27edf464286 100644
--- a/src/mongo/db/commands/mr.cpp
+++ b/src/mongo/db/commands/mr.cpp
@@ -1465,6 +1465,11 @@ public:
if (config.limit && numInputs >= config.limit)
break;
}
+
+ // Record the indexes used by the PlanExecutor.
+ PlanSummaryStats stats;
+ Explain::getSummaryStats(*exec, &stats);
+ coll->infoCache()->notifyOfQuery(txn, stats.indexesUsed);
}
pm.finished();