This page is for engineering teams self-hosting their own Lightdash instance.
Warehouse workers
Process interactive and background warehouse queries on dedicated pods.
Pre-aggregate workers
Materialize pre-aggregates and serve queries from DuckDB.
Requirements
- Helm chart version 2.7.2 or later
- Lightdash version 0.2675.0 or later. Older images will fail with
MODULE_NOT_FOUND.
Upgrading the Helm chart alone does not change how Lightdash works. NATS features are entirely opt-in — your existing deployment will behave exactly the same until you explicitly enable the new Helm values described below.
Architecture
The Lightdash API publishes jobs to NATS JetStream. Worker pods consume messages from their stream and process them concurrently (default 100 concurrent jobs per pod).Enabling NATS
nats.enabled is set to true. This deploys a NATS StatefulSet and sets NATS_ENABLED=true on the backend, which means the backend will start routing queries through NATS. You should always enable at least a warehouse worker alongside NATS to process those queries — otherwise queries will be enqueued with no worker to pick them up.
Auto-configured environment variables
The chart automatically sets these environment variables in the shared ConfigMap — you do not need to set them manually:
Additional environment variables are auto-configured per worker deployment — see Warehouse workers and Pre-aggregate workers for details.
NATS JetStream configuration
JetStream supports two storage backends — we recommend memory store, but you can use file store depending on your needs.Memory store vs file store
For more details, see the NATS documentation on JetStream and stream storage types.
Configuration reference
Pod disruption
NATS is a stateful component — if the NATS pod restarts, in-flight messages are lost (queries will be retried by users). The chart protects against unplanned eviction with:cluster-autoscaler.kubernetes.io/safe-to-evict: "false"annotationPodDisruptionBudgetwithmaxUnavailable: 0