-
Notifications
You must be signed in to change notification settings - Fork 104
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
RPS doesn't decrease when requests stop suddenly #1075
Comments
ah, never mind, looks like this is by design http-add-on/pkg/queue/bucketing.go Lines 105 to 118 in 1e27b39
I'd still like to make an argument that the RPS should decrease if the traffic goes to zero. At the moment, as implemented, if traffic drops from 10 to 0 RPS, it yields a higher RPS metric compared to traffic dropping from 10 to 1 RPS. This intuitively doesn't feel correct to me. wdyt @JorTurFer, @zroubalik? |
fixes: kedacore#1075 Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com>
fixes: kedacore#1075 Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com>
fixes: kedacore#1075 Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com>
) * fix: include trailing 0 window buckets in RPS calculation fixes: kedacore#1075 Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com> * add low level test for request drop to 0 Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com> --------- Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com>
Report
When using RPS as a scaler metric, it works well as long as there is some traffic for a particular
HTTPScaledObject
. But when the traffic suddenly stops, it takes the duration of the window for the RPS metric to jump to0
and until then, it remains steady.Expected Behavior
The RPS should monotonously decrement during the window where there is no traffic.
Actual Behavior
The RPS doesn't decrement if traffic suddenly stops.
Steps to Reproduce the Problem
HTTPScaledObject
withscalingMetric
requestRate
window
elapses, RPS drops to 0 and application finally scales downLogs from KEDA HTTP operator
attached as files
keda-add-ons-http-controller-manager.log
keda-add-ons-http-interceptor.log
HTTP Add-on Version
0.8.0
Kubernetes Version
1.28
Platform
Other
Anything else?
after a little bit of digging, I think this might be due to the implementation of counter middleware. The
Record
for RPS seems to be only called when there is traffic for that particular application and values to the buckets get inserted. It should probably also insert zero values automatically to the buckets when there is no traffic.http-add-on/pkg/queue/queue.go
Lines 67 to 73 in 1e27b39
The text was updated successfully, but these errors were encountered: