SBE stagebuilders should treat metadata uniformly

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Query Execution
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      This is an idea for a simplification in SBE stagebuilders. Currently we have struct PlanStageMetadataSlots with a handful of fields for some of the document metadata fields. In PlanExecutorSBE::initializeAccessors we handle most of them the same way, except for sortKeySlot which has a special case I'm not familiar with.

      Could we replace this with a single `map< MetaType, SlotId >`, and handle all meta fields the same way? This would make SBE unaware of the specific meanings of the different meta fields, which seems like a good thing for modularity: SBE provides low level execution, and higher layers can put whatever data they want into it.

      I noticed this while reviewing SERVER-99589.

              Assignee:
              Unassigned
              Reporter:
              David Percy (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: