It's been more than 50 years since software architecture, as a concept, was invented, but still, project delays and mismanagement still plague the industry. Some things are inevitable because the software ecosystem is a constantly moving target, trust me that is the reality. It’s something that every software engineer has experienced. In this article, I’ll share a different approach to navigating software architectures.
Domain Driven Design (DDD) is an architectural pattern that helps us understand the software that we are building by modeling the classes based on business requirements. Setting aside the technology that you must use and focusing on the problem domain is what this approach is all about. This design pattern are using strategic and tactical modeling tools to solve business problems.
To start, all you need is a pen and paper.
DDD is not about technology. Instead, its all about understanding the problem you’re to solve in a business context.
To understand how the business works, you need to participate in some discussions with your team. This gives you an in-depth understanding of business goals and allows you to carry out software discovery efficiently. Before learning exactly what DDD is, let us discuss layered architecture.
Back then, there were only two layers: presentation and data. So, where is the business logic? Traditionally, business logic has been coded in the presentation layer (a.k.a user interface). This ideally makes development faster - if you are a solo developer. Eventually, layered architecture emerged, dividing code responsibilities into four layers.
In order to understand DDD, we need to be familiar with what actually makes it up.
In domain-driven design, it is vital for software engineers and domain experts to work together. There is no this team vs that team, it’s all one big team.
Creating ubiquitous language will benefit all the people working on the software because both developers and clients speak the same language. Ubiquitous language is the language of business, therefore, the engineer who is working the system must understand the business.
In the meantime, let us consider that the bounded context is a boundary around the system.
The customer inside the bounded context is a ubiquitous language. Therefore, ‘customer’ has a different meaning in each boundary.
The main objective of this design is to identify the bounded context, ubiquitous language, and context map inside the system.
This design is used when you create your domain model inside of your bounded context. The building blocks are entities, value objects, aggregates, services, and repositories.
In software development, there is no single solution to every problem. If you have a small application or the requirements are only essential CRUD functions, I don’t think you need DDD. It all depends on the application that you are building. You can try DDD architecture design if your application grows and has many functions.
I hope you finally understand the basic concept of DDD. In my next article, entities and value objects with some sample codes.
What kind of architectural pattern are you currently using? Are you facing challenges as you scale? Let me know in the comments and don't forget to share this article.
Thanks for reading. (-:
Also published here.