A cluster of associated objects that are treated as a unit for the purpose of data changes. External references are restricted to one member of the Aggregate, designated as the root. A set of consistency rules applies within the Aggregate's boundaries.
Questions tagged [aggregateroot]
441 questions
1
vote
3 answers
DDD: Do all aggregate roots require children?
Everything I have read thus far on DDD implies only entities which encapsulate other entities are root aggregates.
What about in situations like:
WorkOrder
- idManufacturer
- WONumber
- Description
Manufacturer
- idSelf
- Name
WorkOrder…

Alex.Barylski
- 2,843
- 4
- 45
- 68
1
vote
1 answer
What does the choosing consistency type "Ask Whose Job It Is" guidance mean?
When discussing how to decide whether transactional or eventual consistency should be used in Part II of Vaughn Vernon's Effective Aggregate Design, he states
When examining the use case (or story), ask whether it's the job of
the user executing…

George Mauer
- 117,483
- 131
- 382
- 612
1
vote
2 answers
DDD Aggregate Root Persistence
I have a class which is an aggregate root and represents a Person. A person must have a Title ( Mr, Mrs, Ms etc ) which is a property of the Person object. When creating a person the user must select a title from a drop down list the contents of…

Anthony Walters
- 143
- 1
- 12
1
vote
2 answers
Aggregate Roots & Repositories
I'm currently trying to discover the idea behind aggregate roots and their relation to repositories.
Given are the following domain entities:
public class Country {
public string Name { get; set; }
public ICollection Cities { get;…

Acrotygma
- 2,531
- 3
- 27
- 54
1
vote
1 answer
Json.NET serialise root object differently to descendant objects
I am using RavenDB (which itself uses Json.NET) to store documents (or aggregate roots).
When I store an aggregate root, I would like the aggregate roots it references (either directly or indirectly as a descendant of another reference) to only…
user140628
1
vote
3 answers
Aggregate root and value object outside of aggregate
I have an aggregate root "Car"
A car has a list of value objects "Wheels" containing "Wheel" objects.
Since a car should not exist without wheels (at least according to our business logic), in order to construct a car is this valid in proper domain…

Ilan Y
- 107
- 9
1
vote
2 answers
Repository pattern for database and aggregate root
I'm trying to understand the concept of 'aggregate root'.
One of the things that confuses me is that I should not access a child entity directly without accessing its aggregate root. For example, let's say I have a computer entity and a hardware…

Moon
- 22,195
- 68
- 188
- 269
1
vote
1 answer
Does it make sense to make this aggregate roots design?
Let's assume a project presenting those specifications:
Each Employee can organize a Meeting inviting other Employees.
Each Employee can accept the invitation to participate to the Meeting, while the number of max Participations isn't exceeded.
Any…

Mik378
- 21,881
- 15
- 82
- 180
1
vote
2 answers
Delete child entities in a repository
My applications has a repository for each aggregate root, but sometimes I need to remove only one child entity from this aggregate root. How can I do this with the repository pattern?
Ex:
Brand (Aggregate Root)
|_ CarModels (Collection of…

juliano.net
- 7,982
- 13
- 70
- 164
1
vote
2 answers
Aggregate root among ProductCategory, Product, ProductImages
I utilize DDD in my project.
ProductCat[Id , Name]
Product[Id, ProductCatId, name]
ProductImages[Id,ProductId,url]
My Relationship between Product and ProductImages is correct OR ProductImages is Value Object so must implement in this…

Mohammadreza
- 3,139
- 8
- 35
- 56
1
vote
5 answers
DDD/NHibernate Use of Aggregate root and impact on web design - ex. Editing children of aggregate root
Hopefully, this fictitious example will illustrate my problem:
Suppose you are writing a system which tracks complaints for a software product, as well as many other attributes about the product. In this case the SoftwareProduct is our aggregate…

Pat
- 255
- 2
- 4
- 16
1
vote
1 answer
Reference another Aggregate Root inside another Aggregate root?
I'm done DDD for a couple of years now and still its challenging when it comes to designing Aggregates. Thats the fun part of DDD and it makes your head spin. I'm asking this question since I'm architect in a project and we're in the middle of…

Magnus Backeus
- 2,242
- 17
- 24
1
vote
2 answers
Domain Driven Design - Aggregate for transactional consistency
I am developing a CMS type application and am looking to use some ddd tactical patterns. Here is the situation:
The application deals with the authoring and publishing of items.
Items are grouped together in a workflow group. Within that group, one…

JBradshaw
- 151
- 1
- 9
1
vote
2 answers
How do I define aggregate and aggregate roots and link between aggregates
So I am new to DDD and I am trying to design an application correctly. But I am having a bit of difficulty with identifying aggregate roots.
My need is more or less a tree
*Customers
*Each customer can have 0 or more licenses
*Each license can have…

Rickard Liljeberg
- 966
- 1
- 12
- 39
1
vote
1 answer
How to design this domain model?
So I've the following Domain:
Applications and Versions, they are actually software applications
Devices, the devices on which the applications are installed
Installed Applications on Devices
Notification Subscription by installed Applications
So…

Trent
- 5,785
- 6
- 32
- 43