Clean-up MongoProcessInterface::preparePipelineForExecution() OperationContext usage

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

      Pipeline and exec::agg::Pipeline objects as well as find Executors can 'live through' several commands, which is usually the main command (find, aggregate, etc.) plus the following 'getMore()' calls.

      To worked correctly, these objects need to be 're-attached' correctly to the new OperationContext object. As of SERVER-105371, only exec::agg::Pipeline has the corresponding 're-attaching' interface.

      As a part of this ticket, we need to check if this can stay so, and fix some interaction with (optimization) Pipelines to use the correct and valid operation context.

      For instance, MongoProcessInterface::preparePipelineForExecution() takes and uses the operation context from the given Pipeline object, which might not be up-to-date.

            Assignee:
            Unassigned
            Reporter:
            Romans Kasperovics
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: