I have the following Onion Architecture framework.
DomainEntities- For my domain entitiesInterfaces- For my domain interfacesServices- For my domain services
InfrastructureData- ForFluent NHibernatepersistenceInterfaces- For infrastructure interfacesLogging- Just an interface for logging in case I want to switch out my logging library to something else.Dependency Resolution- Most of myIoCregistrations goes in here.
ServicesInterfaces- Application service interfaces goes in here, they will get implemented in theUIproject.
TestsInfrastructure Tests- For testing infrastructure services etc.Domain Tests- For testing domain models and services
WebUI- User interface project where I implement application services, user interface, etc ...
With Domain Driven Development one would identify the Bounded Contexts. Most of the literature on the internet states that each Bounded Context needs to be abstracted into their own project or namespace.
- Is my approach then incorrect for having all my
Domain Modelsin one project and all myDomain Servicesin another project? Does it really matter not having different bounded context's in different namespaces or projects? - If you have a
Model Awhich is used myBounded Context A, butBounded Context B,Bounded Context C, etc also needs to use the exact sameModel A, Do you allow them to use that exact same model, or do you create a new model for eachBounded Context?
I am new to DDD so sorry if this question is a dumb question. I find myself understanding something better if I ask a question and get a good explanation as an answer.
Any Help will be much appreciated.
Aucun commentaire:
Enregistrer un commentaire