Lesson 4.2

Schema migrations without downtime

A migration runs against a live application. Expand, migrate, contract lets you change a schema while both old and new code are running.

31mIntermediate5,747 students
Video thumbnail for Schema migrations without downtime

Sign in to watch this lesson

Browsing is free. Create an account to play videos and track your progress.

Overview

A migration runs against a live application. Expand, migrate, contract lets you change a schema while both old and new code are running.

What this lesson covers

  • Apply the expand, migrate, contract pattern
  • Avoid locks that block writes on large tables
  • Make every migration reversible or forward-only on purpose

This lesson sits in Operating Postgres, part of PostgreSQL for Developers. It assumes what came before it and leads directly into the next lesson in the module.

In this lesson you will:

  • Apply the expand, migrate, contract pattern
  • Avoid locks that block writes on large tables
  • Make every migration reversible or forward-only on purpose
Schema migrations without downtime — Skiply