RE: Returning newly created entities from the aggregate

<[email protected]>
Newsgroups gmane.comp.programming.domain-driven-design
Message-ID <[email protected]>
Hi Matt,
 

 pass in the ID of the sub organization, i.e. RegisterSubOrganisation(subOrganisationID, subOrganisationName). That also avoids the problem of the sub organisational unit being created, but the call not returning to the client for some other reason - resulting in the client not knowing if the sub unit was created, and not knowing how to query for it.
 

 If there is some technical reason you cannot do this, either stick to what Moran advises. or think about polling techniques, which allow you to poll for a result by some value you *pass in* (polling ID), i.e. the command doesn't have to return anything here either.
 

 Enjoy
 Ramin
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.