[SERVER-38314] IndexBuilder::_build should not be interruptible while reacquiring database locks Created: 29/Nov/18  Updated: 29/Oct/23  Resolved: 03/Dec/18

Status: Closed
Project: Core Server
Component/s: Storage
Affects Version/s: 4.0.4, 4.1.5
Fix Version/s: 4.1.6

Type: Bug Priority: Minor - P4
Reporter: Benety Goh Assignee: Benety Goh
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Storage NYC 2018-12-17
Participants:
Linked BF Score: 63

 Description   

For IndexBuilder::_build to clean up failed background index builds, the database has to be locked in specific modes. If the index build was interrupted (for example due to a killOp), the calls to DBLock::relockWithMode(mode) calls will not succeed, leading to an invariant in the MultiIndexBlockImpl destructor.

This issue can be addressed by wrapping DBLock:relockWithMode() calls with an UninterruptibleLockGuard.



 Comments   
Comment by Githook User [ 03/Dec/18 ]

Author:

{'name': 'Benety Goh', 'email': 'benety@mongodb.com', 'username': 'benety'}

Message: SERVER-38314 IndexBuilder should not be interrupted while reacquiring database lock
Branch: master
https://github.com/mongodb/mongo/commit/ce4649cbe2f15fcd40b7b292090c3ab185b4c59f

Generated at Thu Feb 08 04:48:36 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.