-
Type: Task
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: None
-
Labels:None
-
Fully Compatible
-
Query Optimization 2021-02-22
The primary goal of this ticket is to provide an extremely limited proof of concept for the window function stage. The only supported function will be $sum over the window bounds ["unbounded", "current"], as this allows us to completely re-use the existing AccumulatorState machinery. Also, partitioning will not need to be supported.
The subtasks we identified would be:
1. Translate AST-like structures to relevant AccumulatorState (dependency on SERVER-53399)
2. Fail to parse on anything other than the function/window described above.
3. Implement stage getNext() logic to loop through 'output' fields, accumulate value, and project to the output document. May be able to use MutableDocument::setNestedField instead of the full-blown $addFields executor.
4. Verify functionality through mqlrun