A tale from the trenches
summary
How to change a primary key for millions of users across thousands of tenant databases without waking SREs: use low‑level SQL upgrade/downgrade tasks (QueryDSL-wrapped JDBC) for core migrations, reserve Flyway for one‑way, export‑excluded changes, and run risky work as ad hoc upgrade tasks that use feature flags, report progress every five minutes, and can roll back; schedule execution with a pertinent loop and a staged fast five rollout, clone databases for imports, and null out removed columns to keep XML exports compatible.
AI-written summary · about
chapters (13)
- 0:00Introduction and context
- 2:24Product legacy and forks
- 6:46Migration challenges
- 9:51Upgrade and downgrade tasks
- 12:54Implementing upgrade tasks
- 16:12Continuous delivery strategy
- 18:26The 'Fast Five' procedure
- 21:25Feature flags and cleanup
- 24:06Ad hoc upgrade tasks
- 26:44Observability and safety
- 33:14Flyway for schema changes
- 34:24Testing and prevention
- 37:02Q&A and closing
