~/talk

Postgres schema migrations using the expand/contract pattern

Talkat PostgreSQL Conference Europe 2024 · 2024-10-22..10-25· [databases]
links:none on file
slides:none on file

Shows how the expand/contract pattern performs zero‑downtime Postgres migrations by keeping old and new schema live simultaneously, using pgroll to automate the two‑phase start/complete flow. Migrations are expressed as JSON, pgroll creates per‑version schema views and installs triggers for dual‑write so application V1 and V2 see different projections of the same table while a batched backfill runs. Tool is Postgres‑specific, open source (Apache), aims to avoid long exclusive locks and make rollbacks safer by removing added objects during contract.

AI-written summary · about

  1. 0:00Introduction and context
  2. 4:30Common migration pitfalls
  3. 11:13Tools and techniques
  4. 14:22Expand contract pattern
  5. 21:41Introducing pgroll
  6. 25:19Demonstration
  7. 35:33Lessons and takeaways
  8. 38:00Q&A
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.