-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: None
-
Query Optimization
-
Fully Compatible
-
ALL
-
None
-
None
-
None
-
None
-
None
-
None
-
None
The dependency graph can be constructed partially. This is used during Rule-based rewrites.
The graph APIs allow the user to pass nullptr to reference fields at the end of a pipeline.
/** * Returns false if the path as seen at the input of 'stage' can be proven to not be an array. * Returns true otherwise. If 'stage' is nullptr, the path is evaluated as it appears at the end * of the pipeline. */ bool canPathBeArray(const DocumentSource* stage, PathRef path) const;
With a partially-built graph, instead of referencing the end of the pipeline, the nullptr value incorrectly resolves to the end of the covered range.
I don't believe there are currently instances where nullptr is passed for a partially built graph, but this is an issue which will be hit eventually as the graph is used in more places in the codebase and should be resolved.