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

HPA does not support AverageValue for Object metrics #72824

Open
arjunrn opened this Issue Jan 11, 2019 · 2 comments

Comments

Projects
None yet
4 participants
@arjunrn
Copy link

arjunrn commented Jan 11, 2019

What happened: Specifying the averageValue for an Object type metric in the HPA has no effect.

What you expected to happen: The target scaled based on the number of replicas.

How to reproduce it (as minimally and precisely as possible):
Create an HPA with custom metric scaling on an object, for example an ingress like so:

 - type: Object
    object:
      metric:
        name: requests-per-second|sample-custom-metrics-autoscaling-master-7
      describedObject:
        apiVersion: extensions/v1beta1
        kind: Ingress
        name: sample-custom-metrics-autoscaling
      target:
        type: AverageValue
        averageValue: 5

And describe the created HPA. The metrics status is always shown as 0 because the value displayed is the target value which is never specified.

Anything else we need to know?:
The feature is describe in the docs but has not been implemented in the code here. Only the Value is used for calculating the replicas and the AverageValue is never used.

Environment:

  • Kubernetes version (use kubectl version): v1.12.4
  • Cloud provider or hardware configuration: AWS
  • OS (e.g. from /etc/os-release): CoreOS
@danielqsj

This comment has been minimized.

Copy link
Member

danielqsj commented Jan 12, 2019

/sig autoscaling

@MaciekPytel

This comment has been minimized.

Copy link
Contributor

MaciekPytel commented Jan 13, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment