Home United States USA — software Start with Events and DDD When Building Microservices

Start with Events and DDD When Building Microservices


NewsHubDomain-Driven Design (DDD) is a great technique bringing designs closer to the domains we are working in, but too often we make early design decisions with a focus on structure, which is not the intention of DDD. Instead, we should start with the events in a domain, Russ Miles recently claimed while describing advantages of going “events-first” when building microservices.
Miles believes that besides focusing on structure, we are also focusing the ubiquitous language too much on things, especially on domain objects. To make things even worse we have also started to create libraries with domain objects for reuse across domain boundaries, effectively preventing different bounded contexts from evolving separately.
In Miles’ experience, this approach has become the default architecture style for enterprise layered architecture, the reason being to make things easier, not simpler or to help in improving a design. This has caused things, like entities, to move from being ubiquitous in one context to being canonical across all contexts, a direct contradiction with the ideas of DDD.
Instead Miles claims that we should start with what happens in a domain- the events. They are better in capturing the ubiquitous language in a domain, and often the easiest way to describe the domain, especially when collaborating with domain experts.

Continue reading...