[SERVER-42014] [4.0] repairDatabase should catch and report exceptions from repairCollections before re-opening the database Created: 28/Jun/19 Updated: 29/Oct/23 Resolved: 16/Oct/19 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | 4.0.0 |
| Fix Version/s: | 4.0.14 |
| 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: | Execution Team 2019-09-23, Execution Team 2019-10-07, Execution Team 2019-10-21 | ||||
| Participants: | |||||
| Description |
|
In 4.0, we have a cleanup handler in repairDatabase that re-opens the database and its collections when the function exits. If an exception is thrown while repairing a collection, this cleanup handler attempts to re-open all collections before the active exception is caught and reported. If a single collection repair fails by throwing an exception, the cleanup handler tries to re-open all collections in the database before exiting the function. If a failure occurs before all collections have been repaired, the RecordStores may not be reinitialized by a call to reinitCollectionAfterRepair and leads to a fatal assertion. The results in the cleanup handler's error suppressing any actual cause of failure. This is not a problem in 4.2 because of the work done by |
| Comments |
| Comment by Githook User [ 16/Oct/19 ] |
|
Author: {'name': 'Louis Williams', 'username': 'louiswilliams', 'email': 'louis.williams@mongodb.com'}Message: |