Johnny.sh

Autoscaling

Kubernetes can, of course, autoscale your services for you. It does that a lot, actually, that’s basically for what kubernetes was made. It has many options for autoscaling!

  • VPA - Vertical Pod Autoscaling. When you set a request or limit for a pod, it will give more resources/CPU to a pod, up to the limit and at least the requested amount.
  • HPA - Horizontal Pod Autoscaling. When you set this, it will scale the running application replicas (pods) to match changes in application load. HPA scales your application horizontally by increasing or decreasing the number of pods.
     2
   ┌──┐
   │  │
 ┌─▼──┴───────┐ 1   ┌──────────────────┐
 │    HPA     ├────►│  Metrics Server  │
 └─────┬──────┘     └──────────────────┘
       │
       │
       │  3   ┌────────────┐
       └─────►│ Deployment │
              ├──────┬─────┤
              │      │     │
     ┌───────┬┘  ┌───┴───┐ └─┬───────┐
     │ Pod 1 │   │ Pod 2 │   │ Pod N │
     └───────┘   └───────┘   └───────┘
Last modified: January 18, 2023
/about
/uses
/notes
/talks
/projects
/podcasts
/reading-list
/spotify
© 2024