|
SERVER-75648 was part of an optimization in the protocol between mongod and mongot to have mongot avoid doing potentially unnecessary work when the query specifies a limit. The optimization adds a bit to mongod's request to mongot which specifies a requested number of documents it wants from mongot - allowing mongot to avoiding ranking documents that the query doesn't need. However, $idLookup might filter out some results, so this new bit is just a suggestion to mongot, rather than a hard requirement (as opposed to limit pushdown from mongos to mongod).
This ticket is particular adds this bit, named 'mongotDocsRequested', to the explain output of $_internalSearchMongotRemote which represents the number of documents that mongod requested from mongot. Note this is a query planning metric, not an execution time metric - mongot might end up returning more or fewer documents than were requested.
Example explain:
{
|
"mongotQuery": {},
|
"explain": {},
|
"limit": <int>,
|
"sortSpec": {},
|
"mongotDocsRequested": <int>,
|
}
|
|