Space Django: Migrating and Redesigning a Database while Hunting for Satellites.
summary
A startup migrates a messy JSON-backed Postgres schema by copying rows with Django ORM into a redesigned relational schema, running as a CI-invoked management command and tracking progress per-table. The migration keeps a two-database setup (internal vs customer) and uses a mapping dictionary to transform columns plus Django signals for near-real-time sync; scripts handle bulk tables. The approach works for this dataset and deadlines but is sequential, cache-dependent, and not a universal solution.
AI-written summary · about
chapters (19)
- 0:00Space Django project
- 1:54Hunting satellites meaning
- 5:08Initial database challenges
- 9:26Migration goals and time
- 10:30Off-the-shelf migration tools
- 11:34Raw SQL mistake
- 12:20Django ORM for migration
- 13:47Risks in migration files
- 14:52Dual DB access with signals
- 16:18API abstraction layer
- 17:00Database redesign plan
- 18:04Data migration approach
- 21:18Migration logic classes
- 22:22Simple vs complex data
- 23:27Migration performance
- 24:56Sequential loops unavoidable
- 25:41Migration progress tracking
- 26:44Next steps after migration
- 27:47Q&A: Field mapping
related talks
23mDjango with PostgreSQL superpowers
24mOf Django, PostgreSQL schemas, and your multi-million dollar idea
22mDjango with PostgreSQL superpowers
33mAdding zero-downtime migrations strategy in SaaS project
21mDjango's Migrations: A Retrospective
29mMigrating Data Quickly and Safely
57mDjangoCon 2008 Panel: Schema Evolution
33mPeaceful Django Migrations with Efe Öge
