All Items All Items
Aggregates are Transaction Boundaries
Aggregates act as gatekeepers for all changes to domain elements enclosed within itself.
Data changes to an Aggregate and its enclosed domain elements are committed atomically. Either everything within the Aggregate is kept in sync, or the whole state change operation is failed.
Aggregates are loaded in entirety, and an Aggregate's state changes are persisted in a single transaction. A part of the Aggregate not fitting into a single transaction or Aggregates that are too big are indicators that there is a need for a new Aggregate.
Domain Elements within the Aggregate are not accessible directly. They cannot (and should not) be manipulated outside the context of the Aggregate.