Autoscaling with KEDA¶
This feature is still experimental.
KEDA stands for Kubernetes Event Driven Autoscaling.
KEDA is a custom controller that
allows users to create custom bindings to the Kubernetes Horizontal Pod
Autoscaler.
The autoscaler will adjust the number of active celery workers based on the number
of tasks in queued
or running
state.
Enable for the airflow instance by setting workers.keda.enabled=true
in your
helm command or in the values.yaml
.
A ScaledObject
and an hpa
will be created in the airflow namespace.
KEDA will derive the desired number of celery workers by querying Airflow metadata database:
Note
Set celery worker concurrency through the helm value
config.celery.worker_concurrency
(i.e. instead of airflow.cfg or
environment variables) so that the KEDA trigger will be consistent with
the worker concurrency setting.