I have started learning web development, and anywhere I see, the topic of databases always starts with migrations.
From what I've understood for updating databases one should
- Run a "something to generate migrate script" to generate a migration script which would diff your current models file and the current database.
- Test the migration script on your local database.
- Commit the migration script so that it reaches your production environment, wherein run the script again to update your production databases.
But then reading Schema Migrations on Wikipedia from this link Schema Migration I came upon the following text:
schema migration is typically only used when the data held in the database is not real nor valuable, such as in software development, where developers work only with (possibly generated) test data.[citation needed] Programmatic schema migrations are almost never performed in production for the same reason.
I says that one should avoid migrations in prodution, then how are you supposed to update your databases?
Aucun commentaire:
Enregistrer un commentaire