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

fix(prometheus scaler): Detect Inf before casting float to int #3762

Merged
merged 5 commits into from
Nov 4, 2022

Conversation

JorTurFer
Copy link
Member

@JorTurFer JorTurFer commented Oct 20, 2022

Signed-off-by: Jorge Turrado jorge_turrado@hotmail.es

Provide a description of what has been changed

Checklist

  • Commits are signed with Developer Certificate of Origin (DCO - learn more)
  • Tests have been added
  • Changelog has been updated and is aligned with our changelog requirements

Fixes #3644

@JorTurFer JorTurFer requested a review from a team as a code owner October 20, 2022 18:27
@JorTurFer
Copy link
Member Author

JorTurFer commented Oct 20, 2022

/run-e2e prometheus*
Update: You can check the progress here

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
@JorTurFer
Copy link
Member Author

JorTurFer commented Oct 20, 2022

/run-e2e prometheus*
Update: You can check the progress here

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
@JorTurFer
Copy link
Member Author

JorTurFer commented Oct 25, 2022

/run-e2e prometheus*

Update: You can check the progress here

@JorTurFer
Copy link
Member Author

JorTurFer commented Nov 2, 2022

/run-e2e prometheus*
Update: You can check the progress here

@JorTurFer JorTurFer enabled auto-merge (squash) November 2, 2022 15:16
Copy link
Member

@zroubalik zroubalik left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

@bboreham bboreham left a comment

Choose a reason for hiding this comment

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

Code seems fine to me. Maybe the changelog could say "Treat Inf the same as Null result from Prometheus", so you don't have to read through the issue details.

@JorTurFer
Copy link
Member Author

Code seems fine to me. Maybe the changelog could say "Treat Inf the same as Null result from Prometheus", so you don't have to read through the issue details.

Nice suggestion, I have to modify that file to solve the conflicts, I'll do it 🙇

Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es>
@JorTurFer
Copy link
Member Author

JorTurFer commented Nov 4, 2022

/run-e2e prometheus*
Update: You can check the progress here

@JorTurFer
Copy link
Member Author

JorTurFer commented Nov 4, 2022

/run-e2e prometheus*
Update: You can check the progress here

@JorTurFer JorTurFer merged commit 7af0953 into kedacore:main Nov 4, 2022
@JorTurFer JorTurFer deleted the fix-prometheus-error branch November 4, 2022 14:58
@JorTurFer JorTurFer mentioned this pull request Jan 17, 2023
1 task
pedro-stanaka pushed a commit to pedro-stanaka/keda that referenced this pull request Jan 18, 2023
…ore#3762)

* fix(prometheus scaler): Detect Inf before casting float to int

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

* Improve the log message

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
@pedro-stanaka pedro-stanaka mentioned this pull request Jan 18, 2023
7 tasks
pedro-stanaka pushed a commit to pedro-stanaka/keda that referenced this pull request Jan 18, 2023
…ore#3762)

* fix(prometheus scaler): Detect Inf before casting float to int

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

* Improve the log message

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>
pedro-stanaka pushed a commit to pedro-stanaka/keda that referenced this pull request Jan 19, 2023
…ore#3762)

* fix(prometheus scaler): Detect Inf before casting float to int

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

* Improve the log message

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>
pedro-stanaka pushed a commit to pedro-stanaka/keda that referenced this pull request Jan 19, 2023
…ore#3762)

* fix(prometheus scaler): Detect Inf before casting float to int

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

* Improve the log message

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>
JorTurFer added a commit that referenced this pull request Jan 19, 2023
* fix: CVE-2022-3172 (#3693)

Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

* fix: Respect optional parameter inside envs for ScaledJobs (#3694)

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

* fix(prometheus scaler): Detect Inf before casting float to int (#3762)

* fix(prometheus scaler): Detect Inf before casting float to int

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

* Improve the log message

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>

Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

* fix(nats-jetstream): correctly count messages that should be redelivered (waiting for ack) towards keda value (#3809)

* fix: keda now include the messages that should be retried in the count of pending messages used for scaling

Signed-off-by: Antoine Laffargue <antoine.laffargue@gmail.com>

* chore: update changelog

Signed-off-by: Antoine Laffargue <antoine.laffargue@gmail.com>

Signed-off-by: Antoine Laffargue <antoine.laffargue@gmail.com>
Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>

* NewRelic scaler crashes on logging (#3946)

Signed-off-by: Laszlo Kishalmi <laszlo.kishalmi@partech.com>

Signed-off-by: Laszlo Kishalmi <laszlo.kishalmi@partech.com>
Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>
Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

* Fix stackdriver client returning 0 for metric types of double (#3788)

* Update stackdriver client to handle metrics of value type double

Signed-off-by: Eric Takemoto <24865872+octothorped@users.noreply.github.com>

* move change log note to below general

Signed-off-by: Eric Takemoto <24865872+octothorped@users.noreply.github.com>

* parse activation value as float64

Signed-off-by: Eric Takemoto <24865872+octothorped@users.noreply.github.com>

* change target value to float64 for GCP pub/sub and stackdriver

Signed-off-by: Eric Takemoto <24865872+octothorped@users.noreply.github.com>

Signed-off-by: Eric Takemoto <24865872+octothorped@users.noreply.github.com>
Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

* Fixing conflicts after cherry-pick

Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>

* fix: Close is called twice on PushScaler's deletion (#3599)

Signed-off-by: ytz <1020560484@qq.com>
Signed-off-by: taenyang <1020560484@qq.com>
Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>

* fix/datadog-scaler-null-last-point (#3954)

Signed-off-by: Tony Lee <dogzzdogzz@gmail.com>
Signed-off-by: Tony Lee <tony.lee@shopback.com>
Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com>
Co-authored-by: Tony Lee <tony.lee@shopback.com>
Co-authored-by: Zbynek Roubalik <zroubalik@gmail.com>
Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>

* fix(mongodb): escape username and password (#3989)

Fixes #3992

Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

* Hacking generated files to version CI expects

Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>

* Updating aws-sdk and golang packages to fix CVEs

Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

* Updating golang/text package to fix CVE

Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

* Using same version of aws sdk as in main

Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>

Signed-off-by: Pedro Tanaka <pedro.tanaka@shopify.com>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Antoine Laffargue <antoine.laffargue@gmail.com>
Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>
Signed-off-by: Laszlo Kishalmi <laszlo.kishalmi@partech.com>
Signed-off-by: Eric Takemoto <24865872+octothorped@users.noreply.github.com>
Signed-off-by: ytz <1020560484@qq.com>
Signed-off-by: taenyang <1020560484@qq.com>
Signed-off-by: Tony Lee <dogzzdogzz@gmail.com>
Signed-off-by: Tony Lee <tony.lee@shopback.com>
Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com>
Co-authored-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es>
Co-authored-by: Antoine LAFFARGUE <antoine.laffargue@gmail.com>
Co-authored-by: Laszlo Kishalmi <laszlo.kishalmi@gmail.com>
Co-authored-by: Eric Takemoto <eric.takemoto@gocrisp.com>
Co-authored-by: taenyang <1020560484@qq.com>
Co-authored-by: Tony Lee <dogzzdogzz@gmail.com>
Co-authored-by: Tony Lee <tony.lee@shopback.com>
Co-authored-by: Zbynek Roubalik <zroubalik@gmail.com>
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.

Detect Inf before casting float to int
3 participants