Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-58431

Modify HashAgg stage in preparation for $lookup + $group pushdown

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 5.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Fully Compatible
    • Query Execution 2021-07-26
    • 162

      Two important changes must be made to HashAgg:
      1) It should have a flag for whether or not to recompute the hash table on calls to re-open. In the case where the HashAgg is on the right side of an NLJ and there are no correlated variables below it (or used in the HashAgg itself), we can safely skip any re-computation. This will be an important optimization to have for the way $lookup will be translated.
      2) It should have an option to "look up" a particular group key chosen at runtime. That is, on re-opens, when the hash table is already built (and does not need to be re-built) the stage should simply position itself at this key and then return EOF.

            Assignee:
            martin.neupauer@mongodb.com Martin Neupauer
            Reporter:
            ian.boros@mongodb.com Ian Boros
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: