[SERVER-58888] $unionWith explain with mode "executionStats" does not account for stages which are pushed down Created: 27/Jul/21 Updated: 29/Oct/23 Resolved: 30/Jul/21 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 4.4.11, 5.0.4, 5.1.0-rc0 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Nicholas Zolnierz | Assignee: | Nicholas Zolnierz |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||||||
| Operating System: | ALL | ||||||||||||||||||||||||
| Backport Requested: |
v5.0, v4.4
|
||||||||||||||||||||||||
| Participants: | |||||||||||||||||||||||||
| Description |
|
This is very similar to
However, there was an oversight with the implementation whereby the inner $match can actually come from a rewrite for a pipeline like this:
which gets optimized to:
The current explain output for the second example does not include the $match pushdown, and subsequently may not show the correct access plan (e.g. IXSCAN on _id). |
| Comments |
| Comment by Githook User [ 19/Oct/21 ] |
|
Author: {'name': 'Nick Zolnierz', 'email': 'nicholas.zolnierz@mongodb.com', 'username': 'nzolnierzmdb'}Message: (cherry picked from commit 432d231645aa6496a291996a1385409b08bcd7dc) |
| Comment by Githook User [ 18/Oct/21 ] |
|
Author: {'name': 'Nick Zolnierz', 'email': 'nicholas.zolnierz@mongodb.com', 'username': 'nzolnierzmdb'}Message: (cherry picked from commit 432d231645aa6496a291996a1385409b08bcd7dc) |
| Comment by Vivian Ge (Inactive) [ 06/Oct/21 ] |
|
Updating the fixversion since branching activities occurred yesterday. This ticket will be in rc0 when it’s been triggered. For more active release information, please keep an eye on #server-release. Thank you! |
| Comment by Githook User [ 30/Jul/21 ] |
|
Author: {'name': 'Nick Zolnierz', 'email': 'nicholas.zolnierz@mongodb.com', 'username': 'nzolnierzmdb'}Message: |