Jenkins and plugins versions report
I am seeing that if i try to lock multiple resources with the "extra" parameter, and i have entries of both "resource" and "label" they trigger this line from the LockableResourceManager: "Extra filter tries to allocate pre-reserved resources."
The comment in the file describes perfectly what im trying to do:
Resource1 has label LABEL_A
Resource2 also has LABEL_A
If i try and do:
Lock(
extra: [
{resource:'Resource1'},
{label: 'LABEL_A'}
])
It will sometimes try and aquire the label first which has a chance of aquiring the lock for the named required resource. Would it be possible to update this to first lock all named required resources and then lock by label? I believe this might fix the issue
What Operating System are you using (both controller, and any agents involved in the problem)?
Linux Debian(Trixie) using docker containers
Reproduction steps
- Create 2 resources sharing the same label
- Try and lock by both label and name
Expected Results
Aquiring both locks
Actual Results
Aquires only 1 lock
Anything else?
No response
Are you interested in contributing a fix?
To whichever capacity i can help with (im not fluent in java)
Jenkins and plugins versions report
I am seeing that if i try to lock multiple resources with the "extra" parameter, and i have entries of both "resource" and "label" they trigger this line from the LockableResourceManager: "Extra filter tries to allocate pre-reserved resources."
The comment in the file describes perfectly what im trying to do:
If i try and do:
It will sometimes try and aquire the label first which has a chance of aquiring the lock for the named required resource. Would it be possible to update this to first lock all named required resources and then lock by label? I believe this might fix the issue
What Operating System are you using (both controller, and any agents involved in the problem)?
Linux Debian(Trixie) using docker containers
Reproduction steps
Expected Results
Aquiring both locks
Actual Results
Aquires only 1 lock
Anything else?
No response
Are you interested in contributing a fix?
To whichever capacity i can help with (im not fluent in java)