-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
StatefulSet not scaled #1940
Comments
Is this really related to StatefulSet? What happens if you use Deployment? From the HPA logs seems like, that it doesn't need to scale. Are you sure that your query is correct? |
Also if all you want to scale on is CPU usage, normal HPA objects (or the passthrough for HPA's cpu/memory metric scaling) might be a better fit than roundtripping through Keda. |
@zroubalik Sorry for confusion. I do not think so it related to StatefulSet. I can change issue title if you want. Looks like HPA controller divide current metrics by no. of current replica ref. In this situation Currently we have 2 pod hence current metrics(91) get divided by 2 ie. 46. Trigger value is 75 so HPA never thinks it should scale. if above theory is right not sure how people scaling stuff on aggregated metrics which are not related to the no. pod. Please let me know if I am wrong this my attempt understand why. @coderanger |
All metrics computations can be in either Value or AverageValue mode. In general this is currently hard-coded per scaler based on the first use case it dealt with. There is a vague plan to make it configurable and more consistent overall but for now just check each scaler's code to see which mode it uses. |
I think that it is pretty safe to say that all scalers are using AverageValue mode. https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/#algorithm-details |
Just for a reference: #1314 for enabling Value mode for Rabbit MQ, but I'd rather see it done on a global level, as @coderanger mentioned. |
Thanks for confirming the behavior & providing ref. Any idea how you guys think it should get implemented? |
Suggestion Any thoughts on exposing
|
I would love to see some generic approach for all scalers. The only thing I am concerned about is what would be the actual behavior when there will be mutliple triggers in one ScaledObject with mixed metric target types? For example 2 triggers in ScaledObject, first using So eventually we would need to set this setting on a ScaledObject level and apply to all triggers? But I am not sure about this and we need some investigation on this topic. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
This issue has been automatically closed due to inactivity. |
Report
keda not able to scale StatefulSet even triggers condition meet. Check attached screen shot where threshold beyond the trigger(75) in keda metrics but StatefulSet not have scaled .
Expected Behavior
After crossing threshold StatefulSet should have scaled.
Actual Behavior
After crossing threshold StatefulSet not scaled.
Steps to Reproduce the Problem
Logs from KEDA operator
KEDA Version
2.2.0
Kubernetes Version
1.19
Platform
Amazon Web Services
Scaler Details
prometheus
Anything else?
Not sure why current value in hpa is 46 ?
The text was updated successfully, but these errors were encountered: