Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lock All resources by setting quantity to 0 is not documented #198

Closed
akomakom opened this issue Apr 23, 2020 · 1 comment · Fixed by #199
Closed

Lock All resources by setting quantity to 0 is not documented #198

akomakom opened this issue Apr 23, 2020 · 1 comment · Fixed by #199

Comments

@akomakom
Copy link
Contributor

Experimentally I discovered that setting quantity to zero results in locking all resources with the given label. In other words, quantity: 0 is the same as quantity: 100 if there are 100 resources.

lock(label: 'my-label', quantity: 0) {
}

This is either an undocumented feature or an unintended result.

  • If it's undocumented, I'm happy to supply a PR for the readme and jelly.
  • If it's not to be relied upon, please let me know.

I personally find this to be a useful feature.

@akomakom akomakom changed the title Lock all by setting quanity to 0 is not documented Lock All resources by setting quantity to 0 is not documented Apr 23, 2020
@TobiX
Copy link
Contributor

TobiX commented Apr 23, 2020

JonasScharpf added a commit to JonasScharpf/lockable-resources-plugin that referenced this issue Dec 12, 2024
mPokornyETM pushed a commit that referenced this issue Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants