Relational Database Schemata
Explore strategies for managing relational database schema changes in deployments to maintain system stability. Understand how to apply safe schema updates using expansion and cleanup phases, employ shims to bridge old and new schema versions, and test migrations thoroughly with real production data to avoid failures.
We'll cover the following...
Programmatic control
Database changes are one of the driving factors behind “planned downtime,” especially schema changes to relational databases. With some thought and preparation, we can eliminate the need for dramatic, discontinuous, downtime-inducing changes. We probably have a migration framework in place already. If not, that’s definitely the place to start. Instead of running raw SQL scripts against an admin CLI, we should have programmatic control to roll our schema version forward.
Remember: It’s good for testing to roll it backward as well as forward, too.
Safe schema changes
While a migrations framework like Liquibase helps apply changes to the schema, it doesn’t automatically make those changes forward-and back-ward-compatible. That’s when we have to break up the schema changes into ...