MyWarehouse
MyWarehouse copied to clipboard
Infrastructure.Persistence module does not utilize IEntityTypeConfiguration
The Clean Architecture Template utilizes IEntityTypeConfiguration
to separate EF Core configuration on a per-entity basis.
This sample project does not utilize this technique, which makes this aspect of the design of the Persistence module arguably inferior. (The reason for this peculiar omission is that originally I didn't actually use the template, but started from an empty default solution, to force myself to engage more with the design instead of relying on a predefined structure.)
Task:
- Spread out entity configurations from
ApplicationDbContext
into classes implementingIEntityTypeConfiguration
. - Try to keep owned type configuration centralized in some way (since it seems currently all references to these types, e.g. Money, have to be configured individually, including their value conversion, even though this configuration is basically the same in all cases).