DDD is a way to design software program. It most useful then you have to deal with complex domain so it helps to reduce complexity of the system. If domain is not complex, you should consider to use another software architecture technic.
Why Use Domain-centric Architecture?
Pros
Cons
Domain is most important part of application. You start working from domain and not tools
Domain defines code, but code also can affect on domain. You release your app and it can change domain.
DDD is based on Agile principles.
Agile is base on Inspect and Adapt.
The most important part is release small changes and adapt according to feedback.
Stories in Agile
Micro-services and Monoliths
problems with Monolith
Advantages of Microservices
Bounded Contexts and Entities
What are context?
What are the responsibilities of people working within that context?
Entity vs Aggregate
bounded context:
You need to think about responsibilities of people working in context. People in warehouse have different context rather than in book store.
One way to solve a problem with different context. It should a role| one person that should communicate with different context. Usually it happens in real life.
Context is entity. It has one job and doing only one thing and doing it only in specific context.
An aggregate is a collection of entities you talk to through a single portal.
Line between entity and aggregate can be fuzzy:
Ubiquitous language
In different context language may change. In warehouse book will have different properties than in shop. The language itself will be reflected within the code. Developer and architect should use this language with describing features.
Names