Vertical and Horizontal Pod Autoscaling

9/30/2019

Are the metrics for vertical and horizontal scaling in kubernetes the same. So does the cpu,memory and custom metrics work with both concepts?

-- Java
kubernetes

1 Answer

9/30/2019

Yes, Both use the CPU or Memory metrics provided by the metrics server.

For CPU or Memory metrics you can use either VPA or HPA, not both together. Using both together will have undesirable behaviour, because they will be competing to scale up/down/in/out at same time.

Using custom metrics is possible to have both enabled, one can be activated by the CPU or Memory, the other by custom metrics (like number of messages in a queue, active connections)

-- Diego Mendes
Source: StackOverflow