Locking and Unlocking takes very long for no apparent reason.
Take this example pipeline:
This is how the Build-Log looks (sometimes):
here is the first problem. I see the job leaving the node, but not that it tries to lock a resource, that message will be printed after the lock is acquired (even though the timestamp implies something else)!
and the second problem is that it took nearly 10 minutes to get the lock while there was only one other non related job running. So the lock should be obtainable super fast and the overall workload of the system was low.
Not only the jobs seem to have these performance drops, but also when going to <yourjenkins.url>/lockable-resources/ there are times when it takes minutes to see the currently locked resources.