Короткий огляд матеріалу з Dev.to DevOps: A 3 ms ALTER can stall Postgres: how to migrate a 5-billion-row table with no downtime.
An ALTER TABLE that takes 3 ms can still stall every query on the table. In my first demo it took 3 ms. In a second one, on real Postgres, a long transaction held the table, so a similar ALTER waited about 3 seconds, and a plain SELECT that arrived after it waited 2.7 seconds, though it only needed to read. That queue is how a "metadata-only" migration becomes downtime. Here is the method for a 5-
Це адаптований дайджест українською, а не повний передрук статті.
Джерело: Dev.to DevOps

Залишити відповідь