Table des matières

Conception pilotée par le domaine

La conception pilotée par le domaine (Domain-Driven Design, ou DDD) est une approche de conception que a pour principe que la conception est basée sur le modèle et que l'accent doit être sur le domaine et la logique associée 1).

On doit, entre autre :

Les avantages :

While Domain-Driven Design provides many technical benefits, such as maintainability, it should be applied only to complex domains where the model and the linguistic process provide clear benefits in the communication of complex information, and in the formulation of common understanding of the domain.

– Eric Evens, Domain-Driven Design

Les désavantages

Glossaire

The Domain Layer is responsible for representing concepts of the business, information about the business situation, and business rules. State that reflects the business situation is controlled and used here, even though the technical details of storing it are delegated to the infrastructure.This layer is the heart of business software.

– Eric Evens, Domain-Driven Design

Elements of a Domain Model

Anemic vs Rich

Anemic focalise sur l'état d'un objet, alors que le rich domain models focalise sur le comportement et les règles d'affaires du domaine. Quoique le modèle anémique peut être partfait pour le CRUD, celui-ci constitue un anti-pattern dans le contexte du DDD.

Aggregates

Sources

Ressources

Exemples