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

Disable use of SBE on the inner side of DocumentSourceLookup

    XMLWordPrintable

Details

    • Task
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 6.0.2, 6.1.0-rc1, 6.2.0-rc0
    • None
    • Fully Compatible
    • v6.1, v6.0
    • QE 2022-08-22, QE 2022-09-05
    • 135

    Description

      The current state of affairs is that the normal engine selection rules are used when deciding whether SBE or the classic engine should be used for queries issued recursively by DocumentSourceLookup.┬áThis has proven to be problematic for performance, especially for some of the TPC-H benchmarks which we run. In particular, the auto-parameterization rules for the SBE plan cache differ from those for the classic engine's cache – join predicates expressed using $expr will not benefit from plan caching on the inner side, resulting in a substantial performance regression (especially when the plan cache has not yet been populated).

      The work for this ticket is to ensure that the classic engine is always used on the inner side of a DocumentSourceLookup. (The cases in which $lookup is fully pushed down to the SBE layer will not be affected by this change.) This will likely immediately restore performance for a number of TPC-H queries. It also seems like a useful simplification in that we will not support this relatively complicated "hybrid plans" scenario in SBE until we are confident that basic cases are performing well.

      Attachments

        Issue Links

          Activity

            People

              david.storch@mongodb.com David Storch
              david.storch@mongodb.com David Storch
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: