-
Type:
Improvement
-
Resolution: Unresolved
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Query Execution
-
QE 2025-06-23, QE 2025-07-07
-
None
-
3
-
TBD
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Pipeline::dispose() currently takes OperationContext* parameter. According to the method's comment this is necessary, because a pipeline can be disposed when the pipeline's own operating context is for some reason not valid anymore, but it is hard to spot / understand such cases.
In cases when it is actually so, we could probably call Pipeline::reattachToOperationContext(OperationContext*) before calling Pipeline::dispose(OperationContext*). 're-attaching' does some additional steps:
- propagate to the stages
- validate
The advantage of such change would be to mark explicitly the cases when the operation context needs to be re-attached.
- related to
-
SERVER-106560 Clean-up MongoProcessInterface::preparePipelineForExecution() OperationContext usage
-
- Needs Scheduling
-