In this kind of scenario I usually have a state machine on the class. Simple states would do Creating, Live Some constraints are added if the state == Creating...
My rule is simple. "Can the child exist without the parent?" [Order] (Order) 1---* (Lines) [OrderLine] If you delete the Order then its lines should also be...
For me there are two types of "Can I" on an object 01: Is it logical for this object to perform this task based on its state. 02: Is it permissible for the...
Hello Jørn, This is a typical "have your cake and eat it" scenario that customers think they'll need. It ends up being utterly dumb data and as soon as your...
I don't think I follow your point, you say you would "use aggregation (prohibit delete)", but in your example its obvious that Person does not sit inside the...
Just as a follow up, thinking about it a bit more, it doesn't really make sense to cascade deletes across aggregate boundaries because you may be breaking...
... [ClassName] (RoleName) One order has many lines. [Order] (Order) 1---* (Lines) [OrderLine] This is a composite association, the order lines will be deleted...
... Just as a follow up, thinking about it a bit more, it doesn't really make sense to cascade deletes across aggregate boundaries because you may be breaking...
That would explain why I didn't follow your point earlier. The Evans concept of an aggregate is different to a UML aggregation association. Regarding your...
Why would you want to perform multiple save operations? Deleting a node and all its sub-nodes is an atomic operation and should therefore occur within a...
Regardless of which way you want to do it (cascade across aggregate roots, or not) you obviously want it to be atomic. The atomicity is not relevant. Given you...
In that case maybe you could explain it to me and I could be educated. Although I do feel that hijacking the word "aggregate" to mean something else from the...
Hi Pete, Check out http://tech.groups.yahoo.com/group/domaindrivendesign/message/7533. With respect to the UML's notion of aggregation, remember these words...
Okay, I haven't read in detail, but the first paragraph or two suggests this is a value type scenario. I recently had to implement value types in an app...
I worked on a project with similar requirements in the past. One question you have to ask yourself is does any *logic* change with any of these customization...
I prefer explicitly Specifying validity context, I usually separate IsValid from IsValidForPersistence, thus the infrastructure would allow saving of entity by...
... Scott, I'm just a newbie, but might I suggest that the Route Specification and Itinerary example in the Ubiquitous Language section of Evan's book is an...
[my google-fu has failed me. if the answer exists elsewhere, please point me to it. thanks] We our dipping our toes into the domain driven waters and have some...
... Hello, I'm new to the group and still only quarter of a way through the book, so I can only answer from my own experience. My apologies it isn't...
Remember that aggregate boundaries are a modeling choices, and they are coevolving with the other modeling choices, such as which classes you want and which...
Today, we are often using looser typing of the domain model. But only for the attributes that do not affect business logic. Simply a key/value construction...
Hi Ged, Thanks for your input! What are your thoughts on the cascading of saves? Are they along the same lines or would you be comfortable with cross-aggregate...
Hi Thomas ... Yes, it ain't really an easy requirement. Mentally I have begun to work with two different extension models, each of which is more complex than...
Hi Randy I think my problem is that I don't have to worry about stuff like this. In my framework I can visually specify delete rules based on UML association...
Hi, Interesting comment on reporting! It will help me in the design of the system I am working on now. We are actually thinking of duplicate models: one DDD...
... Thanks for reminding me about this. I would probably have implented a bunch of switch statements somewhere to check for all the basic types (int, date...
It's funny how the more I obsess over this topic and search the web for opinions, the more my own thoughts have already been...er..thought. Check out this: ...
Thank you, Eric, that provoked a whole bunch of discussion here in our workplace. Plan Periods might turn out to be the appropriate aggregate. A follow up...
Eric gives great advice here, especially in the paragraph below where he questions why people are looking at these smaller slices an perhaps they might be...