DDD Step By Step
A Practical Guide to Domain Driven Design

Repository

Repository

The Repository pattern is a Persistence abstraction in Domain Driven Design.

Repositories behave like a collection of an Aggregate Root, and act as a facade between your Domain and your Persistence mechanism.

As expected from a collection, the Repository should enforce equality consistency with Identity. In languages where default equality is by reference, the Repository should return the same instance for the same identity.

See also:

Blog post: Blogged The Repository Pattern

domaindrivendesign.org on

 

Recent Comments

Leave the first comment for this page.