[SERVER-79551] Support pathless $count over timeseries Created: 31/Jul/23 Updated: 27/Oct/23 Resolved: 30/Aug/23 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Irina Yatsenko (Inactive) | Assignee: | Backlog - Query Integration |
| Resolution: | Gone away | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Assigned Teams: |
Query Integration
|
| Participants: |
| Description |
|
$count query is rewritten as $group+$project over $_internalUnpackBucket stage so it is an include bucket spec but it might have no fields listed if there is no filter prior to counting. Ideally, we should support lowering such queries to SBE but if producing the right count of "empty documents" from the container stages proves to be tricky we should ensure the perf doesn't regress (either because it's OK to lower the prefix of the pipeline or because we block the lowering completely) |
| Comments |
| Comment by Irina Yatsenko (Inactive) [ 30/Aug/23 ] |
|
yoonsoo.kim@mongodb.com Thanks for flagging this! Yes, the recent changes for PM-3324 have modified the plans, created for $count, and we don't need to worry about the correctness of this scenario anymore though |