-
Type: Improvement
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Optimization
-
QO 2024-08-05, QO 2024-08-19, QO 2024-09-02, QO 2024-09-16, QO 2024-09-30, QO 2024-10-14
As we refine our index pruning logic with SERVER-86639 SERVER-86510 and followups, we run the risk of getting the logic wrong in a way that prunes plans that are actually better than the unpruned plans. Pruning a good plan is very bad
To mitigate this, we can write a property-based test using fastcheck. It can create many indexes, and run an explain query with index pruning on and off. Then it can assert that the works done during multiplanning by the pruned plans is always less than or equal to the maximum works from the unpruned plans.
We can write many hand-written tests for future index pruning tickets, but it's easy to miss a case. PBT can help find corner cases we missed.
- is depended on by
-
SERVER-94741 Strengthen index pruning logic
- Backlog
-
SERVER-86510 Always choose covering plan if it satisfies superset of predicates compared to other plans
- Open
- related to
-
SERVER-92147 Pick non-multikey index when two indices are interchangeable
- Closed
-
SERVER-86510 Always choose covering plan if it satisfies superset of predicates compared to other plans
- Open
-
SERVER-82677 Deduplicate index scan + fetch plans guaranteed to have similar performance
- Closed