[SERVER-74453] Implement support for getMore against a mongot cursor created with a user-defined limit Created: 28/Feb/23 Updated: 29/Oct/23 Resolved: 24/May/23 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 7.1.0-rc0, 6.0.7, 7.0.0-rc3, 5.0.20 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Nicholas Zolnierz | Assignee: | Militsa Sotirova |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Assigned Teams: |
Query Optimization
|
||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||
| Backport Requested: |
v7.0, v6.0, v5.0, v4.4
|
||||||||||||||||||||
| Sprint: | QO 2023-05-15, QO 2023-05-29 | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Description |
|
The first batch from mongot may not contain the full set of results for the following cases:
For these cases, mongod should not need to request the full limit for the subsequent getMore. Instead, we could build a method for only requesting (limit - N) results, where N is the number of documents which made it past the $idLookup stage. The actual approach will be left up to the implementation. Note that for storedSource queries, there is no $idLookup stage so the solution should not be tied to the presence of it. Also there is no guarantee that one of the cases above does not happen again for the subsequent getMore, so the solution should be generic and handle this. |
| Comments |
| Comment by Githook User [ 10/Jul/23 ] |
|
Author: {'name': 'Militsa Sotirova', 'email': 'militsa.sotirova@mongodb.com', 'username': 'militsasotirova'}Message: |
| Comment by Githook User [ 02/Jun/23 ] |
|
Author: {'name': 'Militsa Sotirova', 'email': 'militsa.sotirova@mongodb.com', 'username': 'militsasotirova'}Message: |
| Comment by Githook User [ 01/Jun/23 ] |
|
Author: {'name': 'Militsa Sotirova', 'email': 'militsa.sotirova@mongodb.com', 'username': 'militsasotirova'}Message: |
| Comment by Githook User [ 24/May/23 ] |
|
Author: {'name': 'Militsa Sotirova', 'email': 'militsa.sotirova@mongodb.com', 'username': 'militsasotirova'}Message: |