Skip to content

Move Repository Interfaces from Application Layer to Domain Layer #445

Open
@vanasis

Description

@vanasis

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions