Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider how to handle safer database migrations #20

Open
skluck opened this issue Feb 3, 2017 · 0 comments
Open

Consider how to handle safer database migrations #20

skluck opened this issue Feb 3, 2017 · 0 comments

Comments

@skluck
Copy link
Member

skluck commented Feb 3, 2017

There is a pattern that large systems use to handle data migration with zero time - Typically this involves a multi-step migration process:

  1. Add redundant tables or columns and begin writing to both
  2. Switch over reads to the new table/structure
  3. Stop writing to the old structure
  4. Delete the old structure

Etsy and Stripe have written about their experiences with this:

Hal currently uses the doctrine ORM for database management. We need to investigate if using such a pattern is even possible with it. Ideally migrations can happen safely and reliably enough that they can occur while using Continuous Deployment. Not only would this improve our own instance, but also provide a better experience to people using the open source version of Hal.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant