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

Make a deep copy of RuntimeEnvironment for SBE plans to cache

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 5.3.0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Fully Compatible
    • QO 2022-01-10, QO 2022-01-24

      Currently when we copy a sbe::RuntimeEnvironment we only copy the Accessors but the State(including the slots, the type and the state of the slots) is shared among copies. This might cause problems when a real copy of RuntimeEnvironment is needed for Plan caching. 

       

      Imagine a case where some data in the RuntimeEnvironment should not be stored in the SBE plan cache, we would need to strip it out from the RuntimeEnvironment before caching the plan, which could affect the plan being executed. Note that the cached plan and the plan to execute share all the slots in RuntimeEnvironment.

            Assignee:
            ruoxin.xu@mongodb.com Ruoxin Xu
            Reporter:
            ruoxin.xu@mongodb.com Ruoxin Xu
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: