Benefits and Drawbacks of DDD
Compare the benefits and drawbacks of Domain Driven Design in this lesson.
This section will cover the benefits and drawbacks that people may come across when implementing DDD. These will lead to better trade-offs, resulting in the best outcome for companies and projects.
Benefits of Domain Driven Design
Flexibility
When a project is based on Domain Driven Design, it is easier to evolve and change things like business processes, implementations, or technological stack, which gives us a better time to market.
Code is organized
Domain Driven Design can work together with Hexagonal architecture. This concept is going to be covered in the coming lessons. Hexagonal architecture aims to organize the code of an application in a specific structure. It will help developers understand and modify code much easier when necessary.
Business logic lives in one place
When organizing code based on hexagonal architecture, there is a layer where all business objects are placed. It allows for a team to change business logic easier because they should only concentrate on one layer. The yellow hexagon in the image below represents the logic defined by analyzing a business process. Once any business rule changes, it is easy to evolve code in this layer according to new business rules. The business logic code must not spread out other layers.
Create a free account to access the full course.
By signing up, you agree to Educative's Terms of Service and Privacy Policy