Status: Resolved (View Workflow)
A deadlock has been observed between The OldDataMonitor and an AuthorizationStrategy.
When a job has a new build it will call save which will trigger the OldDataMonitor via the SaveableListener.
This will call referTo which in the case of a Run will lookup the parent Job via it's full name. This will perform a permission check .
Now if the authorization strategy is also being saved at the same time then it is highly likely that a deadlock will occur.
- is related to
JENKINS-30060 Listeners are called back whilst holding locks which is prone to deadlocks
- links to
As there's still no RC, we could even still make it part of that. Discussion probably later today in the project meeting.
Code changed in jenkins
User: James Nord
JENKINS-29936 when removing an item use ACL.SYTEM.
The OldDataMonitor should be using ACL.system not the ACL of the calling
thread - this also avoids the deadlock when an authorization strategy is
being saved (locking the auth strategy) which will call into the ODM at
the same point the ODM is being called an a Run has been saved (which will
cause a lookup of the job which will do a permissions check).
(cherry picked from commit 8a077a801960aa74da455441cfb12d300c6d6e3a)
Integrated in jenkins_main_trunk #4292
JENKINS-29936 when removing an item use ACL.SYTEM. (Revision 9a63d6f8cb734d99597c12263f232fc49604eeb0)
Result = UNSTABLE
ogondza : 9a63d6f8cb734d99597c12263f232fc49604eeb0
IMO this is a serious enough bug to be considered for 1.609.3 despite the youth of the fix (CC olivergondza).