KEDA does not scale to zero #2119
Answered
by
tomkerkhove
rafaelarcanjo
asked this question in
Q&A / Need Help
-
Hi, I would like some help, KEDA is not scaling to zero. Where can I go wrong? Thanks.
|
Beta Was this translation helpful? Give feedback.
Answered by
tomkerkhove
Sep 27, 2021
Replies: 3 comments 1 reply
-
Scale to 0 is not supported for CPU as you can see in the docs: |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
tomkerkhove
-
Thanks for replying, I changed the metrics for Prometheus, now it scales to 0. But now replicas don't go out to 0, could you help me again? apiVersion: keda.k8s.io/v1alpha1
kind: ScaledObject
metadata:
name: prometheus-scaledobject
namespace: default
labels:
deploymentName: go-prom-app
spec:
scaleTargetRef:
deploymentName: go-prom-app
pollingInterval: 15
cooldownPeriod: 30
minReplicaCount: 0
maxReplicaCount: 10
triggers:
- type: prometheus
metadata:
serverAddress: http://prometheus-service.default.svc.cluster.local:9090
metricName: access_frequency
threshold: '3'
query: sum(rate(http_requests[2m])) |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Scale to 0 is not supported for CPU as you can see in the docs:
https://keda.sh/docs/2.4/scalers/cpu/