Custom Self-Adapter
Authors/Creators
Description
Custom Self-Adapter (CSA) is a framework for implementing Kubernetes adaptation policies with user-provided logic. A CSA observes a workload and its metrics, evaluates the current state, selects an adaptation strategy, and runs that strategy inside the cluster. The metric, evaluation, and adaptation logic can be written in any language available in the CSA image.
Unlike the Horizontal Pod Autoscaler, a CSA is not limited to the standard replica calculation. Unlike a Custom Pod Autoscaler, it is not limited to changing the replica count. An adaptation script can perform horizontal or vertical scaling, change an image or configuration, or update any other Kubernetes resource allowed by its ServiceAccount.
The project is split into three repositories:
- custom-self-adapter (this repository) contains the Go runtime and the base container images used to run user logic.
- custom-self-adapter-operator installs the
CustomSelfAdapterAPI and manages CSA Pods and their RBAC resources. - k8s-autoscaling-lab provides a reproducible environment for comparing CSA with HPA, VPA, and other autoscaling approaches.