[SERVER-39077] IndexBuilder should always re-lock the database when exceptions are thrown Created: 18/Jan/19 Updated: 29/Oct/23 Resolved: 18/Jan/19 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 4.1.8 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Louis Williams | Assignee: | Louis Williams |
| 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 | ||||
| Sprint: | Storage NYC 2019-01-28 | ||||
| Participants: | |||||
| Linked BF Score: | 31 | ||||
| Description |
|
The IndexBuilder catches exceptions, but if the database isn't locked in MODE_X, instead of exiting and reporting the error, this invariant fails in the IndexBuildBlock. The IndexBuilder should use a ScopeGuard to relock the database on exit so that the destructor of the MultiIndexBlock is never called without the appropriate lock. |
| Comments |
| Comment by Githook User [ 18/Jan/19 ] |
|
Author: {'username': 'louiswilliams', 'email': 'louis.williams@mongodb.com', 'name': 'Louis Williams'}Message: |