-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
gate: allow disabling max concurrent #6053
gate: allow disabling max concurrent #6053
Conversation
Allow disabling max concurrency limit by setting limit to <= 0. Previously it was impossible to disable this limit. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this change, but I wonder if we should use 0
as the no-limit value? Or would it change the existing behavior in an incompatible way?
I doubt it makes much sense to set the limit to 0 as it is because it effectively disables everything 😄 what would be the use-case for that? 🤷 |
In Golang the zero value is usually used to indicate no limit, e.g. setting a timeout of 0 would mean no timeout etc.. Also as you pointed out, making the semantics of |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok nevermind, I just noticed that this is already covered because the condition is <=
:)
LGTM
Allow disabling max concurrency limit by setting limit to <= 0. Previously it was impossible to disable this limit. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com> Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com> Co-authored-by: Matej Gera <38492574+matej-g@users.noreply.github.com> Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
Allow disabling max concurrency limit by setting limit to <= 0. Previously it was impossible to disable this limit. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com> Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com> Co-authored-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
Allow disabling max concurrency limit by setting limit to <= 0. Previously it was impossible to disable this limit. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com> Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com> Co-authored-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
Allow disabling max concurrency limit by setting limit to <= 0. Previously it was impossible to disable this limit. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com> Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com> Co-authored-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
Allow disabling max concurrency limit by setting limit to <= 0. Previously it was impossible to disable this limit.
Signed-off-by: Giedrius Statkevičius giedrius.statkevicius@vinted.com