Skip to content

Stop workloads before pre-upgrade migrations - #164

Merged
charliedowler merged 4 commits into
lightdash:mainfrom
andydennehy:feat/scale-down-backend-on-upgrade
Sep 1, 2026
Merged

charliedowler merged 4 commits into
lightdash:mainfrom
andydennehy:feat/scale-down-backend-on-upgrade

Conversation

@andydennehy

@andydennehy andydennehy commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add authoritative upgrade.mode for the whole release.
  • Recreate stops every database-capable workload before the migration hook. RollingUpdate does not.
  • Keep legacy per-component strategies when the mode is unset. Existing Recreate values still run the shutdown barrier.
  • Remove the separate scale-down enable toggle.
  • Fail closed when shutdown or migration commands fail.

Checks

  • scripts/test-migration-scale-down.sh
  • helm lint charts/lightdash -f charts/lightdash/ci/boot-values.yaml
  • ct lint --all in chart-testing v3.14.0
  • git diff --check
  • Helm docs regenerated with helm-docs v1.7.0
  • Kind upgrade tests on Kubernetes 1.33, 1.34, and 1.35

Fixes SPK-1731

@charliedowler
charliedowler force-pushed the feat/scale-down-backend-on-upgrade branch from debc84f to a22a85f Compare September 1, 2026 11:07
@charliedowler charliedowler changed the title Add optional backend scale-down before pre-upgrade migrations Stop workloads before pre-upgrade migrations Sep 1, 2026
andydennehy and others added 4 commits September 1, 2026 18:05
This stops backend traffic before pre-upgrade migrations so the database is not changed while the app is still serving.
Operators need to know the feature is disabled by default, how to enable it, and that it causes backend downtime.
The pre-upgrade hook now stops every database-capable application Deployment and creates temporary namespace RBAC before the migration Job.
@charliedowler
charliedowler force-pushed the feat/scale-down-backend-on-upgrade branch from a22a85f to 28416ff Compare September 1, 2026 17:06
@charliedowler
charliedowler marked this pull request as ready for review September 1, 2026 17:53
@charliedowler
charliedowler merged commit 1dd49bd into lightdash:main Sep 1, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants