migrations

  • A search index rebuilt because the mapping changed again

    A field that had to change type for the second time in eighteen months, and a rebuild that is now routine. The rebuild time is what makes a…

  • A schema change on a table nobody can lock

    A column type change on a table taking four hundred writes a second, and an ALTER that estimates four hours.

  • The API version that was finally decommissioned

    Version 1, deprecated in March 2025 with a sunset date of December, switched off in January. Nine months of overlap and the date still moved by a fortnight,…

  • Retention split by class, on 900 million rows

    One table with two retention requirements, seven years apart, and no column distinguishing them. The technical work was a generated column and a backfill; the work that took…

  • Anonymising rows that must be kept and must not identify

    Financial records retained for seven years, containing personal data that may not be retained that long. Keeping the postcode district and discarding the rest is the compromise that…

  • The archive table nobody could delete from

    900 million rows, a retention policy, and a legal question nobody had asked. A table that grows forever because deleting from it might be illegal.

  • The read model that finally earned its place

    A projection deleted in 2023 for being premature, rebuilt in 2025 because the query is now eleven seconds.

  • Testing a migration forwards on a copy of production

    A migration tested against an empty schema, run against nine hundred million rows, and taking four hours instead of four seconds. The restore drill already produced a full…

  • Managing WordPress entirely through Composer

    turkerdev/wp-composer, and an install where nothing is committed except a lock file. Core, themes and plugins as dependencies.

  • A partition drop that finally ran

    A partitioning scheme built in 2023 for a retention policy that nobody had authority to enforce until this year. Dropping one partition a day rather than all of…