[SERVER-21527] Race between remove shard and access to database may cause NULL pointer crash Created: 18/Nov/15 Updated: 06/Dec/22 Resolved: 05/May/16 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Sharding |
| Affects Version/s: | 3.2.0-rc3 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Kaloian Manassiev | Assignee: | [DO NOT USE] Backlog - Sharding Team |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Assigned Teams: |
Sharding
|
||||||||||||||||
| Operating System: | ALL | ||||||||||||||||
| Sprint: | Sharding C (11/20/15), Sharding D (12/11/15), Sharding E (01/08/16) | ||||||||||||||||
| Participants: | |||||||||||||||||
| Description |
|
ShardRegistry::getShard will return nullptr if the shard id is not found. In the steady state, the metadata should never contain a database which references a removed shard, because we drain the shard first and clear the cached metadata. However, in theory, there is a very narrow race condition where a query might be referencing a database entry, which points to a shard, which was just removed. |
| Comments |
| Comment by Githook User [ 20/Nov/15 ] |
|
Author: {u'username': u'kaloianm', u'name': u'Kaloian Manassiev', u'email': u'kaloian.manassiev@mongodb.com'}Message: |