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

Update Kafka Scaler to check for ActivationLagThreshold below 0 #4035

Closed
wants to merge 3 commits into from

Conversation

ledleds
Copy link

@ledleds ledleds commented Dec 22, 2022

Signed-off-by: Vicky Ledsom victorialedsom@gmail.com

We were experiencing issues when not providing ActivationLagThreshold, the value is then defaulted to 0 but the logic was checking for a value of less or equal to 0. Which would always fail with must be positive number when using the default. If the plan to keep the default as 0 then this logic needs changing. Hence this PR.

Checklist

@ledleds ledleds requested a review from a team as a code owner December 22, 2022 15:32
Signed-off-by: Vicky Ledsom <victorialedsom@gmail.com>
Signed-off-by: Vicky Ledsom <victorialedsom@gmail.com>
Signed-off-by: Vicky Ledsom <victorialedsom@gmail.com>
Copy link
Member

@JorTurFer JorTurFer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the improvement!
Could you review the tests? TestGetBrokers is failing.
BTW, you can maintain the previous behaviour just not setting activationLagThreshold, the default value is 0 but it isn't checked (the value is only checked in case of set activationLagThreshold), so in case of not providing, KEDA uses 0

@@ -40,6 +40,8 @@ To learn more about active deprecations, we recommend checking [GitHub Discussio

## Unreleased

- **Kafka Scaler:** Don't error when activationLagThreshold is default
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you move this to ### Improvements section?

@zroubalik
Copy link
Member

fixed in : #4143

@zroubalik zroubalik closed this Jan 20, 2023
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 this pull request may close these issues.

None yet

3 participants