Please log in to watch this conference skillscast.

A successful domain model is built through the confluence of several architectural patterns. As Christopher Alexander suggested, you can call these patterns generative when the architecture of the model evolves from the individual patterns similar to how genetic material or DNA generates the form of organisms. An alternative way to think of this is when the domain model as a whole evolves as a compositional structure from each of its piecemeal components.

Functional programming in a statically typed language provides a great substrate for evolution of compositional domain models. The typesystem allows you to define your domain model as an algebra comprising of domain entities as algebraic data types, domain behaviors as functions and domain rules as the laws of the abstractions. You will learn how to approach domain API design through the algebra of types that not only make the APIs statically verifiable but also employ techniques to encode quite a bit of domain logic as part of the API itself.

You will discover Scala as the implementation language, though the techniques discussed will be equally applicable for any functional language with a powerful type system.

During this talk, you will explore the various dimensions of the model evolution starting from inception of the APIs, going through the lifecycles of composition and refinement of the APIs and finally making them resilient through exception handling and effect tracking. Here are some of the design techniques that you will discover:

Domain API evolution through the algebra of types API refinement using techniques like phantom types API composition through algebraic structures like monoid and monad Domain error handling through types Effect handling through types Modularization using techniques like free monads and tagless final

YOU MAY ALSO LIKE: