lockable-resources-plugin icon indicating copy to clipboard operation
lockable-resources-plugin copied to clipboard

Groovy Expression for pipeline

Open pawozakwa opened this issue 5 years ago • 1 comments

I would like to use this plugin in some more advanced scenarios. For example

  • I would like to take all resources with label but with specific description
  • I would like to exclude some resources
  • I would like that every retry to lock different resource retry(3) { lock(label: "LABEL", variable: "VARIABLE", quantity: 1) { def v = VARIABLE // never the same } }

I would be able to handle every case with groovy expression for lock block.

pawozakwa avatar Jul 11 '18 08:07 pawozakwa

The retry part of this issue would be implemented with #185 and #184. You could use the skipIfLocked option to try and lock the resource, if not successful sleep and try again.

tomasbjerre avatar Mar 02 '20 22:03 tomasbjerre