[SERVER-70669] Optimize empty encrypted range queries in aggregation Created: 18/Oct/22 Updated: 05/Dec/22 Resolved: 02/Nov/22 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Queryable Encryption |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Davis Haupt (Inactive) | Assignee: | Backlog - Query Optimization |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Assigned Teams: |
Query Optimization
|
||||||||
| Participants: | |||||||||
| Description |
|
The agg expression:
Currently produces two separate one-sided ranges. This means that lots of work will be done server-side for a query which is known to return no results on the client. Query analysis should optimize this predicate to produce a single encrypted payload that contains no edges. Note that this optimization is only valid without arrays. |