
Modular Monolith with DDD
A sample .NET application showing a modular monolith built with Domain-Driven Design, meant as a reference imp
- Stars
- 14.1k
- Forks
- 2.2k
- Licence
- MIT
- Language
- C#
- Last update
- 2.4 years ago
- Type
- Learning resource
No commits in over a year — check for forks or alternatives before adopting.
What it is
This is a complete example application written in C# for .NET, organized as a modular monolith: one deployable program split into separate modules with clear boundaries. It applies Domain-Driven Design, a way of structuring code around the business domain, and uses a Meeting Groups domain modeled on Meetup.com. The README says its purpose is to show these architectural ideas in a full, production-oriented implementation rather than a small demo.
- Study how modules communicate through APIs and integration events
- Review how CQRS requests are processed within a module
- Read the domain model and unit tests to see DDD tactical patterns in code
- Use the architecture decision log to understand the reasoning behind design choices
Great for
- Developers learning Domain-Driven Design tactical patterns in C#
- Teams comparing modular monolith structure against microservices
- Engineers wanting to see CQRS and unit and integration tests applied together
- Students studying architecture decisions in a realistic codebase
Not ideal for
- Readers who want a quick, minimal starter project, since the README says it is intentionally a full application and not a simple one
- Anyone needing a deployment guide, since the README lists deployment and infrastructure as out of scope
- Teams looking for strategic DDD guidance, since the README explicitly excludes strategic patterns
How to get it
- 1
Clone and build from source
Clone the repository
git clone https://github.com/kgrzybek/modular-monolith-with-ddd - 2
Run it
- Clone the repository to your machine
- Open the solution in a .NET-capable IDE or use the .NET CLI
- Read section 5 of the README (How to Run) for the run instructions, which were not included in the truncated text
- Explore the modules and the architecture documentation in the README
- 3
Get the most out of it
- Read sections 2 and 3 of the README for the domain model and architecture overview before diving into code
- Study the architecture unit tests to see how module boundaries are enforced
- Review the integration tests section to learn how tests are structured
- Pair the backend with the separate React frontend linked in the README
Downloads
Strengths
- The README describes it as a full application with features like authentication and tests, not a toy example
- Documents architecture decisions, C4 diagrams, and testing approaches in detail
- Open source under the MIT license with a large community following
Trade-offs
- The README says deployment, containerization, and infrastructure are out of scope, so you will need to work those out yourself
- The README states it reflects one of many valid approaches, so it should not be treated as the only correct design
- The last push in the metadata is from June 2024, so check whether it still fits your current .NET version
How it compares
| Project | Stars | Type | Level | Updated | Best for |
|---|---|---|---|---|---|
| modular-monolith-with-ddd (this) | 14.1k | Learning resource | advanced | 2.4 years ago | Developers learning Domain-Driven Design tactical patterns in C# |
| CleanArchitecture | 20.7k | Framework | intermediate | 4 days ago | Developers starting a new ASP.NET Core web app or Web API who want a structured layout |
| CleanArchitecture | 18.5k | Framework | intermediate | 2 months ago | C# developers starting a new ASP.NET Core project who want a structured layout |
| eShopOnWeb | 10.7k | App | intermediate | 1.8 years ago | Developers learning ASP.NET Core MVC and clean architecture |
| domain-driven-hexagon | 15k | Learning resource | intermediate | 2.4 years ago | Developers who want to understand Domain-Driven Design and hexagonal architecture through examples |
| aspnetboilerplate | 12k | Framework | advanced | 11 days ago | C# developers already working in the ASP.NET Core ecosystem |
Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.