kubernetes / autoscaler

Autoscaling components for Kubernetes
Apache License 2.0
8.05k stars 3.97k forks source link

Documentation about the Historical Data #4476

Closed mtavaresmedeiros closed 2 years ago

mtavaresmedeiros commented 2 years ago

Hi guys,

I don't find any documentation about the historical data with VPA Recommender, I have a simple question, Can I have historical information with the only metric server? without need to install the Prometheus? if yes, how long this historical information can be?

Thank you.

jbartosik commented 2 years ago

Hi, VPA will always collect and store history while it's running. With Prometheus VPA can load history from before it started.

For example lets say that:

Without loading history from Prometheus:

With loading history from Prometheus:

There is some nuance what happens if you start VPA in the cluster on day 0 but don't create any VPA objects until day 8. I think in that case VPA gathers all data so it's likely to provide recommendation based on 8 days of data if you create a VerticalPodAutoscaler object on day 8. But I think it only saves data associated with a VerticalPodAutoscaler object in checkpoints, so it might have less data if vpa recommender pod is restarted in the meantime.

Please reopen if this doesn't answer your question.