[SERVER-37918] Fast initial split algorithm produces corrupted routing info if passed unsorted zones list Created: 05/Nov/18 Updated: 29/Oct/23 Resolved: 05/Nov/18 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Sharding |
| Affects Version/s: | 4.0.3 |
| Fix Version/s: | 4.0.5, 4.1.5 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Kaloian Manassiev | Assignee: | Kaloian Manassiev |
| 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: |
v4.0
|
||||||||
| Sprint: | Sharding 2018-11-19 | ||||||||
| Participants: | |||||||||
| Description |
|
The fast initial split algorithm operates by iterating the set of zones for a collection and writing chunks for each zone and for each "hole" between zones. However, the main assumption of this logic is that the set of zones comes in sorted order. Otherwise, the results are unpredictable. The current caller of the algorhtm doesn't pass a sort based on the min key of the tags, which means tags could come in the order in which they were inserted, which is not necessarily sorted. This is not a data-loss bug, but it renders the Geo sharding feature unusable in random cases. |
| Comments |
| Comment by Githook User [ 16/Nov/18 ] |
|
Author: {'name': 'Kaloian Manassiev', 'email': 'kaloian.manassiev@mongodb.com', 'username': 'kaloianm'}Message: (cherry picked from commit 8319bd16ad2fdac48db6530570bb5913859509f0) |
| Comment by Githook User [ 05/Nov/18 ] |
|
Author: {'name': 'Kaloian Manassiev', 'email': 'kaloian.manassiev@mongodb.com', 'username': 'kaloianm'}Message: (cherry picked from commit b0c9a1c8419d7a343c2a0496f2cd6a7c0c4d8c92) |
| Comment by Githook User [ 05/Nov/18 ] |
|
Author: {'name': 'Kaloian Manassiev', 'email': 'kaloian.manassiev@mongodb.com', 'username': 'kaloianm'}Message: |
| Comment by Githook User [ 05/Nov/18 ] |
|
Author: {'name': 'Kaloian Manassiev', 'email': 'kaloian.manassiev@mongodb.com', 'username': 'kaloianm'}Message: |