ImEgg
ImEgg
Explore posts from servers
PPrisma
Created by ImEgg on 10/28/2024 in #help-and-questions
Mongodb, Making Breaking changes to production database
I see. According to documentation, the strategy I am referring to would be "all-at-once" updates. From what it sounds like, the best way to go about this is to have the script run in your CI/CD pipeline. if it fails, the push fails and that for every breaking change, there should be 2 separate migrations. the first one adds and moves data to new field. once we do checks and balances and are okay with results we make the second migration to remove old field / data if need be. Please correct me if I'm wrong here. 2nd question. For Prisma with SQL, there is a migration folder and migrations tracker table in the db itself. Is the recommended idea to try and mimic this solution for mongodb if the idea is to do "all-at-once" updates similar to it. Thank you for your help. I appreciate it!
6 replies