CONCEPT Cited by 2 sources
Online DDL¶
Definition¶
Online DDL is the family of techniques for applying schema changes (ALTER TABLE, CREATE INDEX, column adds, type changes, charset changes) to a production database without blocking concurrent reads and writes and without a service outage. At the MySQL altitude, Online DDL spans MySQL's native ALGORITHM=INSTANT / INPLACE options (where the engine can apply the change without a full table rebuild), third-party tools like pt-online-schema-change and gh-ost (which build a shadow table via replication-driven copy + swap), and higher-level orchestration in systems like Vitess's VReplication-driven schema-change workflow. The operator-facing discipline is to analyse each DDL statement against the engine's capability matrix (what can be INSTANT? INPLACE? what requires a shadow-copy rewrite?) and pick the cheapest mechanism that satisfies correctness. Pure performance wins come from extending the INSTANT envelope (no rewrite) and from avoiding engine primitives that are slow inside a rewrite (e.g. CONVERT(... USING utf8mb4) when a programmatic text transform is available).
Seen in¶
-
sources/2026-04-21-planetscale-announcing-vitess-21 — Vitess 21 ships multiple Online DDL improvements:
ALTER VITESS_MIGRATION CLEANUP ALLcommand; moreINSTANTDDL scenario analysis beyond the documented limitations; charset-change handling now uses programmatic text conversion rather than MySQL'sCONVERT(... USING utf8mb4)for performance in primary-key / iteration-key columns; more analysis delegated to theschemadifflibrary for programmatic power + testability. Reintroduced atomic distributed transactions now integrate "with core Vitess components and workflows, such as Online DDL and VReplication (including operations like MoveTables and Reshard)". -
sources/2026-04-21-planetscale-behind-the-scenes-how-schema-reverts-work — canonical wiki walk of the online-DDL shape in the VReplication-driven flavour. Guevara + Noach frame online DDL as a four-step pattern — build shadow with new schema, apply DDL to shadow, backfill + track changes, cut over — shared by
pt-online-schema-change,gh-ost, and Vitess, canonicalised as patterns/shadow-table-online-schema-change. The post then differentiates Vitess on five design properties (copy + changelog progress both tracked; per- transaction GTID mapping; GTID-driven interleaving; transactional sidecar-state coupling; non-termination after cut-over) — the last of which enables instant schema revert: VReplication is kept alive past cut-over and re-primed in the inverse direction, so the old-schema table stays in sync with every post- cut-over write. Canonical new concepts/shadow-table, concepts/cutover-freeze-point, and concepts/pre-staged-inverse-replication concepts and patterns/instant-schema-revert-via-inverse-replication pattern all originate from this post. Positions PlanetScale as the only production MySQL platform that turns a destructive DDL into a reversible, data-preserving operation — strictly stronger than traditional restore- from-backup rollback (no row loss) but weaker than time travel (rows added post-cut-over reappear without values for columns the old schema had that the new one didn't).
Related¶
- systems/vitess
- systems/mysql
- systems/vitess-vreplication
- concepts/shadow-table
- concepts/cutover-freeze-point
- concepts/pre-staged-inverse-replication
- concepts/online-database-import
- patterns/snapshot-plus-catchup-replication
- patterns/shadow-table-online-schema-change
- patterns/instant-schema-revert-via-inverse-replication
- companies/planetscale