Honest Take — Before You Begin
Zero-downtime migrations are the skill that separates senior from staff Rails engineers. Anyone can write addcolumn :users, :role, :string. The staff engineer knows that addindex …
Advanced Topics & Production DBA covers: Learn PostgreSQL, Developing Time-Oriented Database Applications in SQL, Database Internals. Master the operational side of databases — replication, sharding, backup/recovery, zero-downtime migrations, monitoring, and time-series data. This is the module that prepares you to own database infrastructure in production.
Zero-downtime migrations are the defining skill of a production Rails engineer. add_column is safe (no lock on reads or writes). add_index is NOT safe (locks writes) — use algorithm: :concurrently. rename_column is NOT safe (breaks running code) — use a three-step deploy: add new column, backfill, remove old column. change_column (type change) rewrites the entire table — use a new column instead. remove_column can break running code during deploy — use ignored_columns first. The strong_migrations gem enforces all of these. Understanding why each migration is dangerous (table locks, full table rewrites, cache invalidation) comes from understanding database internals (Module 4) and PostgreSQL operations (this module).
This course unlocks once you've finished its prerequisite. Open prerequisite →
Zero-downtime migrations are the skill that separates senior from staff Rails engineers. Anyone can write addcolumn :users, :role, :string. The staff engineer knows that addindex …
Everything else you deploy is disposable. App servers, job workers, caches — kill any of them and a fresh copy boots from an image in seconds, identical and indifferent. The datab…
A customer disputes an invoice from March. Support asks the obvious question: what was this customer's plan and price on March 12th? You open the subscriptions table and find exac…
It's 3 a.m. and the primary has stopped answering. Somewhere in your stack, a piece of software is about to make a decision no human is awake to supervise: declare the primary dea…
Work through each item before the checkpoint.
Ten migrations written the way production DBAs write them — concurrent indexes, phased renames, batched backfills, NOT VALID constraints validated separately — run against a seede…
6 lessons. Read in order; spiral back when you need to. By the end you'll have used the core ideas twice — once on the abstract, once on something you'll meet at work next week.