We've generated ~80 migrations since the release of the 4.3.x version of Entity Framework. Each time we generate a new migration, EF gens a snapshot of the current model for the IMigrationMetadata.Target property.
Since each migration is adding ~135k characters to our assembly, we are starting to hit critical mass. We're now receiving a "No logical space left to create more user strings." compiler error. Combine that w/ the pre-compile views, and you've got a lot of strings.
What's the best long term approach to using EF migrations with a complex model?
Maybe add-migration should be generating these w/ resource files.
we had the same issue. We are also fix this using moving the generated string into resource:
public sealed partial class RegionalCenterRenameClass : IMigrationMetadata
{
// Skipped code
string IMigrationMetadata.Target
{
get { return Targets.M201207110918331_RegionalCenterRenameClass; }
}
}
where Targets - is resource file (resx).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With