[SERVER-62975] PlanExecutorImpl may skip documents returned by PlanStage tree Created: 25/Jan/22  Updated: 29/Oct/23  Resolved: 30/Jun/22

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 6.1.0-rc0

Type: Improvement Priority: Major - P3
Reporter: Ian Boros Assignee: Naomie Gao (Inactive)
Resolution: Fixed Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-62616 Enable reshard*.js tests in sharded_c... Closed
Backwards Compatibility: Fully Compatible
Sprint: QE 2022-07-11
Participants:

 Description   

In PlanExecutorImpl::getNext(), a result is skipped if the caller requests a record ID but none is provided on the WSM produced by the PlanStage tree.

This can result in some very confusing behavior for internal users of PlanExecutor, where documents are filtered out at the PlanExecutor layer. We should consider changing the behavior in this case to tassert() or log an error message instead of simply filtering out the document. If a caller is expecting a RecordID and the plan is not producing RecordIds, it indicates an issue in the way the plan was constructed.

This issue has no known external impact.



 Comments   
Comment by Githook User [ 30/Jun/22 ]

Author:

{'name': 'Naomie Gao', 'email': 'naomie.gao@mongodb.com', 'username': 'naogao'}

Message: SERVER-62975 Tassert on working set member no record ID
Branch: master
https://github.com/mongodb/mongo/commit/2a18721a97ef29fe7e037ebca0131cdb1b99c57c

Comment by Ian Boros [ 25/Jan/22 ]

CC haley.connelly.

Generated at Thu Feb 08 05:56:34 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.