liveBook · Manning

Domain-driven design

As explained in Functional Design and Architecture: Examples in Haskell

Domain-driven design is a software development methodology that centers software design on the concepts, relationships, and rules of the problem domain.

Domain-driven design centers software design on the problem domain: its concepts, relationships, rules, and business logic. It responds to domains blurred across thousands of pieces by favoring simple, readable, adequate abstractions that make the domain easier to reason about. section 5.0

A practical domain-driven design approach:

  • Model the domain explicitly instead of hiding business rules inside scattered implementation details. section 5.0
  • Use domain-specific languages to encode valid operations and prevent avoidable bugs through well-chosen abstractions. section 5.4
  • Represent complex domain structures with algebraic data types, and organize embedded DSLs by meaning, scope, responsibility, and hierarchy. section 5.4
  • Separate domain notions from implementations using runtime lifetimes, object-oriented interfaces, or type-level polymorphism. section 5.4

How Functional Design and Architecture: Examples in Haskell covers it

How deep it goes
Develops domain modeling through abstractions, algebraic data types, embedded DSLs, organization, and decoupling rather than detailed implementation recipes.
Examples
Uses algebraic data types, interpretable embedded DSLs, runtime objects, and interfaces as domain-modeling artifacts.
What you can do after
Build domain-specific languages that encode business rules, restrict invalid operations, and organize domain complexity.
How it connects
Connects domain modeling with domain-specific languages, embedded DSLs, algebraic data types, type systems, and object-oriented interfaces.

Also explained in

Compare how 7 books explain domain-driven design →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Functional Design and Architecture: Examples in Haskell. The section links point to the parts of the book it draws on.