[SERVER-46290] Skip evaluation of tautoligical MatchExpressions Created: 20/Feb/20  Updated: 29/Oct/23  Resolved: 22/Feb/20

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 4.3.4

Type: Bug Priority: Major - P3
Reporter: Justin Seyster Assignee: Justin Seyster
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Query 2020-03-09
Participants:

 Description   

The planner can produce a QuerySolutionNode with a MatchExpression filter of the form {$and: []} (or similar) that will always evaluate to true.

During execution, the PlanStage checks the filter for each document it processes. If we NULL out the filter, however, the PlanStage skips the filter check, saving a small amount of time.



 Comments   
Comment by Githook User [ 22/Feb/20 ]

Author:

{'name': 'Justin Seyster', 'username': 'jseyster', 'email': 'justin.seyster@mongodb.com'}

Message: SERVER-46290 Skip evaluation of tautoligical MatchExpressions
Branch: master
https://github.com/mongodb/mongo/commit/4f19251bf88e2394c464ce2d3f1b83b3cbe9513e

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