The deployment froze. The database migration was stuck, waiting on a single new column.
Adding a new column should be simple, but in real systems, it can bring risk. Schema changes can block writes, lock tables, and halt production traffic. A careless ALTER TABLE on a high-traffic database can cascade into downtime. That’s why planning and executing the addition of a new column requires precision.
The first step is understanding your database engine’s behavior. In MySQL, adding a non-null column with a default value often triggers a full table rewrite. In PostgreSQL, adding a nullable column can be instant, but setting a default without NULL may still rewrite data. Knowing how your engine handles column modifications lets you avoid dangerous locks.
Next, define a clear migration strategy. Create the new column as nullable, then backfill in controlled batches. Use idempotent scripts. Monitor query performance before and after. For large datasets, run the process during low-traffic windows or leverage online DDL where supported. Always test the change in an environment that mirrors production load and scale.