keda: `metricName` shouldn't be required and should be deprecated for all the scalers
Proposal
Currently, some scalers require a metricName which is used only for KEDA internal things (it’s not sent to the prom server).
This requirement isn’t necessary since we introduced mechanisms to ensure the unique metrics names inside the ScaledObject and we should make it optional and also deprecate it in favour of self-generated internal name
Scalers:
- aws-cloudwatch - metric name is needed for this one
- azure-log-analytics
- azure-monitor
- azure-storage-blob
- cassandra
- couchdb - just lefover in the code, doesn’t have to be included in the docs and deprecations
- graphite
- huawei-cloudeye - metric name is needed for this one
- influxdb
- mongodb
- mssql
- postgresql
- prometheus
- rabbitmq-queue
TODO list
- code change to print warning message with deprecation notice https://github.com/kedacore/keda/pull/4235
- update documentation to specify deprecation notice - our deprecation policy - https://github.com/kedacore/governance/blob/main/DEPRECATIONS.md https://github.com/kedacore/keda-docs/pull/1074
- create a new issue to actually remove this code once deprecation period is over (mark it this way: https://github.com/kedacore/keda/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3Abreaking-change) - https://github.com/kedacore/keda/issues/4240
- update deprecation notice in the Changelog https://github.com/kedacore/keda/pull/4235
- create discussion for the deprecation like these: https://github.com/kedacore/keda/discussions/categories/deprecations
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 19 (18 by maintainers)
Links to this issue
- [gprd] Update Helm release keda to v2.10.0 (!1816) · Merge requests · GitLab.com / GitLab Infrastructure Team / Kubernetes Workloads / GitLab Helmfiles · GitLab
- [pre] Update Helm release keda to v2.10.0 (!1819) · Merge requests · GitLab.com / GitLab Infrastructure Team / Kubernetes Workloads / GitLab Helmfiles · GitLab
- [gstg] Update Helm release keda to v2.10.0 (!1817) · Merge requests · GitLab.com / GitLab Infrastructure Team / Kubernetes Workloads / GitLab Helmfiles · GitLab
- [ops] Update Helm release keda to v2.10.0 (!1818) · Merge requests · GitLab.com / GitLab Infrastructure Team / Kubernetes Workloads / GitLab Helmfiles · GitLab
@JorTurFer
https://github.com/kedacore/keda/pull/4235 will complete the tasks “code change to print warning message with deprecation notice” and “update deprecation notice in the Changelog”.
https://github.com/kedacore/keda-docs/pull/1074 will complete “update documentation to specify deprecation notice…”.
Sure, I will do one of them this week (I have a trip today and I’ll be outside until Wednesday night)
Yeah, I will do a round checking all the scalers. I rename this issue with a generic title to track the new issues I’ll create
Nice catch @dttung2905 I have checked the code, and azure_monitor scaler uses metricName for the request, so it’s correctly added in the scaler and we don’t have to remove it
I think this is done
Should we create the discussion now or maybe as part of the release @kedacore/keda-core-contributors ? I guess that we should open it during the release, because maybe the new way of doing the things isn’t release yet (not in this specific case)
Some more scalers to add to the task list (based on searching
metricNamein v2.10 docs):What should be done:
anything else @kedacore/keda-core-contributors ?
@JorTurFer I could help with 1 or 2. If you can do 1 first as an example, I could look at it and see what are needed to be changed 🙏
@JorTurFer could you please identify those scalers and create a separate issues for them? And give them good first issues/help wanted labels? As these could be ideal issues for newcomers.