The One Question To Haunt Everyone: What is a DDD Aggregate?
summary
Argument: an Aggregate is a concrete unit of consistency and unit of concurrency with a single aggregate root as the only entry point; invariants must be enforced inside the boundary, not leaked out. Examples use PHP repository code showing bad vs good APIs, an execution plan with >100 tables to motivate data locality, and the claim that cross-aggregate rules are eventual consistency—keep aggregates as small as necessary, store their parts together, and avoid exposing internal references.
AI-written summary · about
chapters (11)
- 0:00Introduction to DDD Aggregates
- 1:12Why Aggregates are needed
- 5:03What is an Aggregate
- 9:26Aggregate root and boundaries
- 12:19Aggregate as unit of concurrency
- 15:06Aggregate life cycle and identity
- 17:37Data locality in Aggregates
- 20:31Aggregate as unit of distribution
- 22:42Handling multiple Aggregates
- 24:33Aggregate size and boundaries
- 26:00Summary and Q&A
