I recently tried a lot of different stuff with lightweight migration. These all work:
1) Rename attributes (with renaming identifier specified)
2) Add attributes
3) Add new entity + new attribute + inverse relationship to an already existing entity
4) remove existing entit开发者_如何学运维y + relationships to that entity
= It almost looks like just about anything can be handled with LM. Did I miss something? In which cases am I getting into trouble and need an some more complex approach?
Splitting one entity into two different entities (Person > Child & Adult) will not work with automatic migration.
Applying logic (renaming a parameter based on a condition of another parameter) will not work.
Most of your basic migrations can be handled by automatic. Dealing with logic decisions requires a mapping model or custom migration code.
精彩评论