fix: send raw metrics also during polling interval#7198
fix: send raw metrics also during polling interval#7198zroubalik merged 2 commits intokedacore:mainfrom
Conversation
|
Thank you for your contribution! 🙏 Please understand that we will do our best to review your PR and give you feedback as soon as possible, but please bear with us if it takes a little longer as expected. While you are waiting, make sure to:
Once the initial tests are successful, a KEDA member will ensure that the e2e tests are run. Once the e2e tests have been successfully completed, the PR may be merged at a later date. Please be patient. Learn more about our contribution guide. |
There was a problem hiding this comment.
Pull Request Overview
This PR fixes the raw metrics streaming feature to send metrics during polling intervals in addition to HPA requests. It introduces a new RAW_METRICS_MODE environment variable to control when raw metrics are sent.
- Adds configurable raw metrics modes (all, HPA-only, or polling-interval-only)
- Implements logic to send raw metrics during ScaledObject polling intervals
- Refactors raw metrics configuration into a dedicated file
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| pkg/scaling/scale_handler_raw_metrics.go | Introduces raw metrics mode parsing and decision logic with new environment variable support |
| pkg/scaling/scale_handler.go | Updates raw metrics sending calls to use new mode-aware function and adds polling interval support |
| CHANGELOG.md | Documents the fix for raw metrics streaming during polling intervals |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
/run-e2e internal |
Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com>
|
/run-e2e internal |
|
I am a nit picker on commit messages regarding spelling errors 😇 |
haha, thanks a lot!, fixed |
…etter clarity Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com>
|
/run-e2e internal |
Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com>
Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com> Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz>
* Fix incorrect 'unmatched input property' notification (#7176) * Fix incorrect 'unmatched input property' notification Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * Remove redundant parsing Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * fix Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * use typedconfig once Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * static check Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * Update test Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * Update datadog_scaler_test.go Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * update schemas Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * fix test Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * update typedconfig Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * Update pkg/scalers/datadog_scaler.go Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> --------- Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> * fix: add missing error returns in kafka scaler error handling (#7182) * fix: add missing error returns in kafka scaler error handling Add missing error returns after error logging in getTopicPartitions and getLagForPartition functions to prevent incorrect behavior when errors occur. - Add error return in getTopicPartitions when listCGOffsetResponse.Err > 0 - Add error return in getTopicPartitions when topicMetadata.Err > 0 - Add error return in getLagForPartition when block.Err > 0 Previously these functions only logged errors but continued execution, which could lead to incorrect scaling behavior. Signed-off-by: leeyeonwoo <rexrex1105@gmail.com> * docs: update changelog for PR #7182 Signed-off-by: leeyeonwoo <rexrex1105@gmail.com> --------- Signed-off-by: leeyeonwoo <rexrex1105@gmail.com> Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> * Fix incorrect 'unmatched input property' notification (#7188) * Fix incorrect 'unmatched input property' notification Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * add azure cloud Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> * fix Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> --------- Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> * fix: feature flag for unexpected scaler param check (#7191) Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com> Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> * Update prometheus dependency version (#7194) Updated prometheus dependency version to v0.54.0. Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> * fix: send raw metrics also during polling interval (#7198) Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com> Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> * update changelog Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> * . Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> * fix changelog Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> --------- Signed-off-by: Rick Brouwer <rickbrouwer@gmail.com> Signed-off-by: Jorge Turrado <jorge.turrado@mail.schwarz> Signed-off-by: leeyeonwoo <rexrex1105@gmail.com> Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com> Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com> Co-authored-by: Rick Brouwer <rickbrouwer@gmail.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: leeyeonwoo <74847519+5iing@users.noreply.github.com> Co-authored-by: Jan Wozniak <wozniak.jan@gmail.com> Co-authored-by: Zbynek Roubalik <zroubalik@gmail.com>
Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com> Signed-off-by: Dmitriy Altuhov <altuhovd@gmail.com>
Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com>
Signed-off-by: Zbynek Roubalik <zroubalik@gmail.com>
Fix for raw metrrics stream #7094
RAW_METRICS_MODEwith support for:allor""(empty): Send all raw metrics (both HPA and polling) - defaulthpa: Send raw metrics only from HPA requestspollinginterval: Send raw metrics only from polling intervalallChecklist
Fixes #7197
Relates to #7094