[SERVER-85146] [CQF] Interaction between CQF fast path queries and plan cache tests Created: 12/Jan/24  Updated: 02/Feb/24  Resolved: 02/Feb/24

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 7.3.0-rc2

Type: Task Priority: Major - P3
Reporter: Ben Shteinfeld Assignee: William Qian
Resolution: Fixed Votes: 0
Labels: auto-reverted
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by SERVER-67607 Run plan cache tests w/CQF FF enabled In Progress
Problem/Incident
causes SERVER-85852 Fix RHEL80 Debug + TSAN test failure In Code Review
Related
related to SERVER-85728 Enable Bonsai plan cache tests involv... Backlog
Assigned Teams:
Query Optimization
Backwards Compatibility: Fully Compatible
Sprint: QO 2024-02-05
Participants:
Linked BF Score: 0

 Description   

Many plan cache tests issue queries and then use $planCacheStats to examine the contents of the cache. Many of these are simple queries (single equality predicate) that qualify for the newly introduced CQF fast path (SERVER-82171). The fast path does not add plans to the cache nor does it consult the cache to get plans, causing many tests to fail which expect certain cache entries to be present. Since these test assume simple queries end up in the cache, but the fast path prevents this, I think we should disable the fast path for these tests. An alternative is to modify the tests to use more complex queries which are not eligible for the CQF fast path.

A preliminary list of tests which I found that are affected is:

  • jstests/core/index/index_filter_commands_invalidate_plan_cache_entries.js
  • jstests/core/query/plan_cache/plan_cache_clear.js
  • jstests/core/query/plan_cache/plan_cache_sbe.js
  • jstests/core/query/plan_cache/plan_cache_sbe_hinted.js
  • jstests/core/sbe/from_plan_cache_flag.js
  • jstests/core/sbe_plan_cache_autoparameterize_collscan.js
  • jstests/noPassthrough/plan_cache_hits_and_misses_metrics.js
  • jstests/noPassthrough/sbe_plan_cache_size_metric.js


 Comments   
Comment by Githook User [ 30/Jan/24 ]

Author:

{'name': 'William L Qian', 'email': '1192680+wqian94@users.noreply.github.com', 'username': 'wqian94'}

Message: SERVER-85146: Run CQF plan cache tests with fast path disabled) (#18461)

GitOrigin-RevId: ad523c8b712b81848152a3e7ea1f37f543593c0f
Branch: master
https://github.com/mongodb/mongo/commit/350d434bd5fdf2ec2643cce4806fe220c2e84e6f

Comment by Githook User [ 29/Jan/24 ]

Author:

{'name': 'auto-revert-processor', 'email': 'dev-prod-dag@mongodb.com', 'username': ''}

Message: Revert "SERVER-85146: Run CQF plan cache tests with fast path disabled (#18157)"

This reverts commit da6ec75ad6941b751da70b0599ebb74e86f17eef.

GitOrigin-RevId: 03008dbdbaf50bc7763d40cb9ce6081b3e668e95
Branch: master
https://github.com/mongodb/mongo/commit/c8fb075316079be1d66960e2be163d07993e714c

Comment by Githook User [ 27/Jan/24 ]

Author:

{'name': 'William L Qian', 'email': '1192680+wqian94@users.noreply.github.com', 'username': 'wqian94'}

Message: SERVER-85146: Run CQF plan cache tests with fast path disabled (#18157)

GitOrigin-RevId: da6ec75ad6941b751da70b0599ebb74e86f17eef
Branch: master
https://github.com/mongodb/mongo/commit/810b6663f79e5918e14c2279147c5cfdf70da8c1

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