The State of Online Schema Migrations in MySQL

This post provides a comprehensive overview of online schema migrations in MySQL, contrasting native `INPLACE` and `INSTANT` DDL with external solutions. It details the caveats of `INPLACE` (resource greedy, replication lag, uninterruptible) and `INSTANT` (limited scope, metadata-only changes, risks with `DROP COLUMN`). It then elaborates on the common design and characteristics of external tools like Vitess, gh-ost, and pt-online-schema-change, emphasizing their ability to handle almost all schema change types, respect production workloads, and offer interruptibility, while noting potential limitations with foreign keys and partitioning. The post concludes that for the vast majority of changes, external tools are the preferred solution, and suggests using them consistently even for simpler changes supported by `INSTANT` DDL to avoid complexity.