The worst production incidents we've seen usually came from database migrations that seemed routine, not from bugs. This risk applies whether you're running a single well-organised monolith or a distributed system; in the latter, it tends to compound. A column rename that looked innocuous, a NOT NULL constraint added to a table that turned out to have more rows than anyone had checked, an index that locked a table for twenty minutes during peak traffic.
These are almost always avoidable, and the technique isn't exotic. It's a specific way of thinking about schema changes that most teams never get taught.
The Mental Model: Schema and Code Are Versioned Together
The source of most migration pain is the assumption that schema and code are deployed as a single atomic unit. They aren't. There's always a window (sometimes seconds, sometimes longer) where the running code doesn't match the current schema.…