[SERVER-77181] Implement query settings support in Bonsai Created: 16/May/23 Updated: 14/Nov/23 |
|
| Status: | Open |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Denis Grebennicov | Assignee: | Backlog - Query Optimization |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Assigned Teams: |
Query Optimization
|
||||||||||||||||
| Participants: | |||||||||||||||||
| Description |
|
Based on the current design, query settings will only be supported for queries handled by the multiplanner for both Classic and Nebari engines. Once Bonsai becomes available it would be great to make them support query settings as well. The tasks would be:
|
| Comments |
| Comment by Denis Grebennicov [ 14/Nov/23 ] |
|
I am not sure we should do anything about Bonsai and index filters, since we deprecate index filters in PM-412 and hopefully will remove them in 9.0 Not sure adding support for it is worthy, unless it's trivial. I would want query settings to add support for forced indexes and then all types of hints would be represented via query settings alone and then there would be no need for handling 3 different types of hints. Maybe this could be done as part of rich hints project :shrug: |
| Comment by Hana Pearlman [ 14/Nov/23 ] |
|
We'll probably want to do part of the "support index hints specified using persistent query settings in Bonsai" subtask in M2. Specifically, it's possible through query settings to hint a collscan (via {$natural: +1/-1}), which is supported in M2. The same is true for index filters set via planCacheSetFilter, so we'll want to make sure that we're supporting this as well, and correctly handling the hierarchy of index filters, index hints on a query, and index hints from query settings. It may make sense to do this work together here. |
| Comment by David Storch [ 24/Jul/23 ] |
|
Putting this in the M2 correctness project per discussion in optimizer huddle. We don't actually think we should implement it yet because the persistent query settings project is ongoing, but we also don't want to forget about it. Also, we should consider splitting this work into two subtasks: one for adding queryEngineVersion:"v3" (we should reopen duplicate ticket Marking as blocked on the "enable feature flag" ticket for the persistent query settings project. |
| Comment by David Storch [ 14/Jul/23 ] |
|
Per Slack discussion with denis.grebennicov@mongodb.com this is not going to be done as part of the current project, so I'm putting this into the triage queue to find it a new home. |