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

Migrations: Team environments can break rebuilds #996

Closed
bricelam opened this issue Oct 31, 2014 · 3 comments
Closed

Migrations: Team environments can break rebuilds #996

bricelam opened this issue Oct 31, 2014 · 3 comments
Assignees
Labels
area-migrations closed-out-of-scope This is not something that will be fixed/implemented and the issue is closed. type-enhancement

Comments

@bricelam
Copy link
Contributor

Imagine the following scenario.

  1. DevA scaffolds a migration adding ColumnX from Table1
  2. DevB scaffolds a migration that rebuilds Table1
  3. DevA commits
  4. DevB pulls with no conflicts in the model snapshot and commits
  5. DevC pulls and runs Apply-Migration

When Table1 is rebuilt, it will not contain ColumnX. This is because when DevB's migration was scaffolded, it did not know about ColumnX.

This will be true whether we rebuild by "binding" to the model or by scaffold an imperative table rebuild.

@rowanmiller
Copy link
Contributor

We should revisit the idea of keeping a Git style tree of migrations, we may not need to try and solve this issue but we could warn when we detect multiple heads and let devs know that they need to verify things work as expected. It seems like the cases where you hit issues like this are way less now that we have the combined snapshot.

@rowanmiller
Copy link
Contributor

rowanmiller commented Nov 10, 2014

Team Triage: We're making a lot of progress on team environments in EF Core and it seems like it only falls down in edge cases now. We should come back and look at these in the future though and see if we can do something better.

@ajcvickers
Copy link
Member

Leaving on the backlog to consider what we can do with regards to squashing, rebasing, etc of migrations. See also #2167 and #2174.

@ajcvickers ajcvickers closed this as not planned Won't fix, can't repro, duplicate, stale Oct 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-migrations closed-out-of-scope This is not something that will be fixed/implemented and the issue is closed. type-enhancement
Projects
None yet
Development

No branches or pull requests

4 participants