Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move Repository Interfaces from Application Layer to Domain Layer #445

Open
vanasis opened this issue Feb 13, 2023 · 0 comments
Open

Move Repository Interfaces from Application Layer to Domain Layer #445

vanasis opened this issue Feb 13, 2023 · 0 comments

Comments

@vanasis
Copy link

vanasis commented Feb 13, 2023

Hi, Can i know your reason to put Repository layer inside of application layer?
why you dont put it inside domain layer?
is it possible to move it in next versions?

link:
https://stackoverflow.com/questions/71996305/repository-implementation-in-application-domain-and-infrastructure-layer-ddd/72036702#72036702

The repository is the contract between the domain model and the persistence. It should be written only in terms of the Domain and without a thought to the underlying persistence. The contract of a repository is more than just a CRUD interface. It is an extension of the domain model and is written in terms that the domain expert understands. Your repository should be built from the needs of the application use cases rather than from a CRUD‐like data access standpoint

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant