[DOCS-7802] Conflicting documentation on sorting in a sharded cluster Created: 03/May/16 Updated: 30/Oct/23 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | manual, Server |
| Affects Version/s: | None |
| Fix Version/s: | Server_Docs_20231030 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Michael Clovis | Assignee: | Kay Kim (Inactive) |
| Resolution: | Won't Do | Votes: | 0 |
| Labels: | Cleanup | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
All Environments |
||
| Participants: | |
| Days since reply: | 1 year, 14 weeks, 2 days ago |
| Epic Link: | DOCSP-1769 |
| Description |
|
I am a TA at MongoDB U. There is conflicting and i believe dated information on how and where sorting occurs in a sharded cluster. It is our belief that with a sorted query NOT using the aggregation framework, the mongos router sends the query to the necessary shards where the results are fetched and sorted. That data is sent to the mongos router for a merge sort. If the sorted query uses the aggregation framework, each shard that is used to fetch and sort (prior to 3.2) would send the results to the primary shard for the merge sort which would then send the results to the mongos. After 3.2, if the primary shard is not used to fetch the data, the results can be sent to any of the shards that have been used for this query for the merge sort and then sent to the mongos. The information in the FAQ https://docs.mongodb.org/manual/faq/sharding/#how-does-mongodb-sort-queries-in-sharded-environments The information in the manual We believe that "How mongos Handles Query Modifiers" needs to be cleaned up to specify that this is for aggregation framework queries. it seems to be left over from earlier behavior (prior to 2.6) If our understanding is incorrect, please advise. |
| Comments |
| Comment by Education Bot [ 31/Oct/22 ] |
|
Hello! This ticket has been closed due to inactivity. If you believe this ticket is still important, please reopen it and leave a comment to explain why. Thank you! |