MENU

Fun & Interesting

Domain Modeling with Domain-Driven Design (From Scratch)

Milan Jovanović 29,813 1 year ago
Video Not Working? Fix It Now

☄️ Master the Modular Monolith Architecture: https://bit.ly/3SXlzSt 📌 Accelerate your Clean Architecture skills: https://bit.ly/3PupkOJ 🚀 Support me on Patreon to access the source code: https://www.patreon.com/milanjovanovic Domain-Driven Design is a set of principles for how you can design and model a rich domain in your application. In this video, I'll do a domain modeling exercise from scratch. I'll start with a diagram of a domain model and then I'm going to apply some Domain-Driven Design patterns to create the domain models. Join my weekly .NET newsletter: https://www.milanjovanovic.tech Read my Blog here: https://www.milanjovanovic.tech/blog Chapters 0:00 What we are building 1:09 Creating the first Entity 2:36 Value Objects - why they are useful 5:00 Defining an Entity base class 6:07 Using the Static Factory pattern 7:33 Decoupling side effects using Domain Events 10:13 Writing unit tests for the Name value object 13:48 Implementing custom guard clauses 16:02 Writing unit tests for the User entity

Comment