SERVER-99002Backlog

$collStats collection scan counter does not account for repeated scans done by SBE NLJ plans

SBE supports nested loop join (NLJ) plans for executing $lookup queries. Such plans will perform a collection scan of the inner collection for every document read from the $lookup's outer side. Following my example from the attached repro script, imagine a $lookup from an "outer" collection to an "inner" collection on the "key" field, where each collection contains the following documents: There are 4 documents on the outer side. Therefore, an NLJ plan would scan the inner collection 4 ti

Affected Versions
Versions known to exhibit this issue

No affected versions recorded.

Fixed Versions
Versions that include the fix

No fix available yet.

Components
Server components related to this issue

No components specified.

Labels
Tags and classification

No labels assigned.