[SERVER-36907] Make sure deadline is not Date_t::max() when we early return due to lock timeout Created: 28/Aug/18  Updated: 29/Oct/23  Resolved: 24/Sep/18

Status: Closed
Project: Core Server
Component/s: Internal Code
Affects Version/s: None
Fix Version/s: 4.1.4

Type: Bug Priority: Major - P3
Reporter: Maria van Keulen Assignee: Maria van Keulen
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Related
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.0
Sprint: Storage NYC 2018-09-10, Storage NYC 2018-09-24, Storage NYC 2018-10-08
Participants:
Linked BF Score: 39

 Description   

In the DBLock constructor, we early return if _globalLock was not successfully locked. This early return was added as part of SERVER-32682 to account for deadline running out. However, in cases where deadline is Date_t::max(), we expect _globalLock.isLocked() to be true at this point, since this deadline is unreachable. An invariant should be added that the deadline is not Date_t::max() before early returning in this case.



 Comments   
Comment by Githook User [ 24/Sep/18 ]

Author:

{'name': 'Maria van Keulen', 'email': 'maria@mongodb.com', 'username': 'mvankeulen94'}

Message: SERVER-36907 Ensure deadline is not max in lock timeout code path
Branch: master
https://github.com/mongodb/mongo/commit/0d6364ec0a8db3192fc7046ad4ef3c2d5983662a

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