2. Who am I?
● Final year Computer Science student at
Queen’s University Belfast.
● Previously worked at IBM for a year.
● Open sourced projects for QRadar.
● Constantly working on side projects, most of
them open source.
3. Why open source?
● To have a greater chance that someone
will find it and use it.
● To get more responsive feedback per
release.
● Community led feature suggestion, bug
reporting, and use case explanation.
● Kubernetes ecosystem is open source
oriented.
4. Kubernetes and autoscaling
● Kubernetes allows sharing resources
between applications.
● Built on container technology, such as Docker,
standardising applications into units with
infinite scalability potential.
● Autoscaling is the act of balancing which
applications need more or less resources
based on criteria and metrics.
● Horizontal Pod Autoscaler inbuilt method for
autoscaling, generally used to scale on
CPU/Memory.
5. The Problem
● The Horizontal Pod Autoscaler has a
hard-coded equation for calculating how to
scale.
● Custom metrics go some way to help with
this, but ultimately still constrained by core
equation.
● If more complex scaling logic required (e.g.
conditional logic, queues), a custom
autoscaler is required.
● Custom autoscalers are difficult and time
consuming to create, requiring knowledge of
the Kubernetes API and Kubernetes lifecycle.
6. The Goal
● Make autoscalers quick and easy to make,
with limited Kubernetes knowledge required.
● Abstract away complicated Kubernetes API
interactions.
● Autoscaler logic writeable in any language,
framework or environment, and should be
simple enough to be contained in a single
script.
7. Custom Pod Autoscaler Framework
● Works by integrating user provided logic, written in any language or
framework, with a program to abstract away Kubernetes interactions.
● Allows quick and easy autoscaler development.
● Fast prototyping and experimentation.
● Any logic that can be started with a shell command can be used.
● Runs in the Kubernetes cluster as a pod.
● Fully configurable, supports everything the Horizontal Pod Autoscaler
can be configured with.
● Allows configuration without master node access, allowing use on
managed providers such as EKS or GKE.
9. Predictive Horizontal Pod Autoscaler
● Allows use of statistical models
coupled with standard autoscaling
metrics.
● Can predict future demand based on
historical data - preemptively scaling
rather than reacting to demand.
● Can see reductions in latency spikes
if configured and tuned correctly.
10. Any questions?
Some (maybe) useful links
jamiethompson.me
github.com/jthomperoo/custom-pod-autoscaler
github.com/jthomperoo/predictive-horizontal-pod-autoscaler