Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I solve similar problems building (at least) two assembly for each bounded context:</p> <ol> <li>One for the contracts (event, exceptions, shared identifiers and so on...)</li> <li>One for the implementation of entities.</li> </ol> <p>This way, different bounded contexts implementations can reference to the same contracts, without any cicle.</p> <p><strong>edit</strong><br> As for naming conventions, I usually name assemblies after the "conventional name" of the bounded context, for example </p> <ol> <li>BankName.FinancialAdvisory for the contracts</li> <li>BankName.FinancialAdvisory.POCO for the implementations</li> <li>BankName.FinancialAdvisory.ORMOrOtherTechnologicalCouplingName when I need to specialize some class to use them in a specific technological environment.</li> </ol> <p>However, inside the POCO assembly the root namespace is the same of the contracts' one (eg BankName.FinanicalAdvisory): this because the POCOs, that expresses the business rules in code without any technological concern, have the same development livecycle of the contracts. On the contrary the assembly containing technological specializations uses a root namespace that is equals to the assembly name (such as BankName.FinancialAdvisory.ORMOrOtherTechnologicalCouplingName).</p> <p>Nevertheless all the assembly related to the domain share the same namespace structure: for example if a namespace "Funds" exists under BankName.FinancialAdvisory it also exists in both POCO and ORMOrOtherTechnologicalCouplingName (if it contains any class, of course).</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload