Domain-driven design (DDD) is an approach to develop software for complex needs by connecting the implementation to an evolving model.

learn more… | top users | synonyms (1)

4
votes
3answers
462 views

Scrum, DDD, and front-end development in an enterprise environment

So, I've been working for a bank for the past 4 years. My main responsibility has been online banking. Over the past year, we've been implementing the scrum methodology. We've also changed to domain ...
9
votes
3answers
1k views

Validation and authorization in layered architecture

I know you are thinking (or maybe yelling), "not another question asking where validation belongs in a layered architecture?!?" Well, yes, but hopefully this will be a little bit of a different take ...
9
votes
3answers
2k views

When should an Aggregate Root contain another AR (and when should it not)

Let me begin by first apologizing for the length of the post, but I really wanted to convey as much detail up-front so I don't take your time going back and forth in comments. I am designing an ...
1
vote
1answer
349 views

Drawback of implementing DDD service as static class?

Can Services in a domain-driven design be implemented as C# static class? What are the drawbacks of this choice? Can it be implemented as a non-singleton non-static class?
3
votes
4answers
239 views

How to decide whether to implement an operation as Entity operation vs Service operation in Domain Driven Design?

I am reading Evans's Domain Driven Design. The book says that there are entity and there are services. If I were to implement an operation, how to decide whether I should add it as a method on an ...
6
votes
5answers
5k views

Application layer vs domain layer?

I am reading Domain-Driven Design by Evans and I am at the part discussing the layered architecture. I just realized that application and domain layers are different and should be separate. In the ...
16
votes
5answers
909 views

Do ORMs enable the creation of rich domain models?

After using Hibernate on most of my projects for about 8 years, I've landed on a company that discourages its use and wants applications to only interact with the DB through stored procedures. After ...
1
vote
1answer
372 views

DDD and validation of aggregate root

Suppose an aggregate root : MailConfiguration (wrapping an AddressPart object). The AddressPart object is a simple immutable value object with some fields like senderAdress, recipentAddress (to make ...
1
vote
1answer
86 views

Question about state and domain objects

Suppose I create a domain object called UserAdministration, if i have a method called CreateUser how would i pass state to this method, would I create properties on the UserAdministration object and ...
3
votes
1answer
711 views

Forcing aggregate root child access through the aggregate root alone

Context I'm developing an application using a Domain Driven Design approach. I want to use a design pattern wherever appropriate and apply all SOLID principles. Scenario I have an order and I want ...
3
votes
1answer
491 views

what does “domain” mean when referring to DDD

What does the word domain mean regarding driven design/development? Not in terms of semantics or a scholarly definition but in terms of how it modifies processes or philosophies? I was reading a ...
4
votes
2answers
300 views

How should I include third-party models in my domain model?

I'm currently trying to design a little application using Domain Driven Design but I'm afraid I don't really get the concept yet. Let me try to explain this as clearly as possible. public interface ...
6
votes
3answers
270 views

Computed Values and Simple Reads - A nagging pain for my Domain Driven Designs!

The problem I continually face is how to deal with computed values driven by domain logic while still working efficiently against the data store. Example: I'm returning a list of Products from my ...
18
votes
6answers
15k views

Difference between a service class and a Helper class

I would like to know what differentiates a Service class from a utility class or a helper class? A class only with underlying methods calls the dao's is a service? Doesn't the usage of Helper ...
1
vote
1answer
257 views

Is it ok to call external services or database inside the entity

I have "logic engine" which executes set of user configured steps. These steps are saved in the database as "Step" entities. The engine gets the first step and then executes steps until there are no ...
2
votes
1answer
404 views

How to model a many to many from a DDD perspective in UML?

I have a two entity objects Site and Customer where there is a many to many relationship. I have read you try not to model this in DDD as it is in the data model and go for a unidirectional flow. If ...
3
votes
2answers
858 views

What is a value object in domain-driven design?

I have an entity and I've realised that there is a group of properties that work together. So, I moved them to a value object (together with their behavior) and now I have a reference from my entity ...
9
votes
3answers
1k views

Are Domain Objects in Domain Driven Design only supposed to be write-only?

I've been reading about Domain Driven Design for almost two years and have been cautiously been introducing some concepts in to my daily work or at least making plans for how things I do regularly ...
0
votes
4answers
305 views

To which layer does this code belong?

When I say "Revisional Data Model", I mean a data model where information is never lost: Deletes never destroy any rows, and updates always cause an insert somewhere else to preserve a row's previous ...
5
votes
3answers
3k views

DDD with ORM where should the business logic go?

I have used an MDA (model driven architecture) tool in the past where we modeled via UML and this generated the business entities (our domain model) and the ORM (mapping etc) amongst other things. A ...
4
votes
2answers
1k views

Should I use an aggregate root when designing my repository?

I have an entity that is called Master which is composed of a number of Slave entities. There can only be one Master in my database and I want to query repositories to get the Slave for a given id. ...
12
votes
4answers
3k views

What is Domain Driven Development in practical terms?

I heard about Domain Driven Development from a developer in the area. He talked it up like it was just about the silver bullet to changing requirements. I read the wiki. Still not too clear. What ...
11
votes
4answers
518 views

Avoiding bloated Domain Objects

We're trying to move data from our bloated Service layer into our Domain layer using a DDD approach. We currently have a lot of business logic in our services, which is spread out all over the place ...
16
votes
3answers
3k views

Where we should put validation for domain model

I still looking best practice for domain model validation. Is that good to put the validation in constructor of domain model ? my domain model validation example as follows: public class Order { ...
15
votes
2answers
635 views

Is DDD-Lite a pattern language for dependency injection?

I stumbled upon Greg Young's talk 7 Reasons why DDD Projects Fail where he mentions something he calls DDD-Lite at 7:20. Summarizing, he basically says some use DDD as a pattern languages (entities, ...
6
votes
1answer
412 views

Do ORM POCOs replace domain entities?

This is somewhat similar to this question but more broad. In general, with ORMs like EF 4.1 supporting POCOs, does it now make sense to have your domain entities be the objects that are persisted to ...
7
votes
4answers
2k views

Is it bad practice for services to share a database in SOA?

I have recently been reading Hohpe and Woolf's Enterprise Integration Patterns, some of Thomas Erl's books on SOA and watching various videos and podcasts by Udi Dahan et al. on CQRS and Event Driven ...
5
votes
2answers
324 views

How to define the seams between the domain layer and a database full of stored procedures?

We have a legacy database full of stored procedures. These stored procedures are somewhat CRUD-categorized but upon inspection of some procedures, they are not "simple" as they might update, delete, ...
11
votes
2answers
3k views

DDD - Does an aggregate root's repository handle saving aggregates?

I am using a DDD-like approach for a greenfield module of an existing application; it's not 100% DDD due to architecture but I'm trying to use some DDD concepts. I have a bounded context (I think ...
3
votes
1answer
241 views

How a .NET dev team should be designing and delivering greenfield projects? [closed]

Some of the hottest topics in the software world atm are: Domain-Driven Design SOLID principles Agile methodologies ORM Now assuming that you are not currently using all of these in your team, ...
6
votes
2answers
2k views

Command handlers and DDD

I have an ASP.NET MVC application, that uses a query service to get data and a command service to send commands. My question is about the command part. If a request comes in, the command service uses ...
6
votes
3answers
1k views

Inject dependency as method parameter instead of constructor parameter

I'm using an ORM which doesn't allow me to inject dependencies in the constructor. Let's say I'm using DDD for the business logic, and the MVC pattern for the UI. Now one of my domain objects needs ...
2
votes
1answer
277 views

Should the domain model include all the domain entities in my project?

I have currently reading Grails and I love it. In order to get hands on experience with Grails I decided to create a web application for some Management System. Ya as you can guess there are plenty of ...
12
votes
1answer
2k views

Domain-Driven-Design - external dependencies in the Entity problem

I'd like to start Domain-Driven-Design, but there are several problems I'd like to solve before starting :) Let's imagine I have a Groups and Users and when user wants to join a group, I'm calling ...
4
votes
4answers
297 views

Data access for composable applications

I'm wondering if anyone can share their thoughts, experience and guidance on how to approach the data access layer for a composable application? By composable application, I mean an application with ...
5
votes
1answer
189 views

Tools to support learning a new business domain

Suppose you just accepted a job, writing code in an industry sector that you've never worked in before. To be effective, you want to immerse yourself in the business domain - to understand the ...
8
votes
1answer
1k views

Architecting a modular service application

I'm looking at architecting a new solution that is very modular by nature and would like to create a structure that supports that design to allow for easy future expansion, clear separation of ...
45
votes
5answers
5k views

With all of these services, how can I not be anemic?

Where do we draw the line between delegation and encapsulation of business logic? It seems to me that the more we delegate, the more anemic we become. However, delegation also promotes reuse and the ...
4
votes
2answers
2k views

DDD – A rookie’s unanswered questions

I’ve decided to use DDD in one of my pet projects to find out what the fuss is about! Let me start off by saying that this (DDD) is the way software SHOULD be written, I’ve seen some strange patterns ...
14
votes
7answers
958 views

What is the best practice for gathering requirements when a customer does not know what he wants? [duplicate]

Possible Duplicate: How do you deal with changing requirements? This question must have been asked a thousand times but there seems to be little progress in this area: I have asked the ...
0
votes
2answers
139 views

Which layers should reflect the domain language (if a domain language can strictly exist)?

This question relates to a one I asked earlier: http://stackoverflow.com/questions/5448574/under-what-conditions-could-we-justify-an-attempt-to-introduce-a-one-size-fits-al When re-reading ...
3
votes
3answers
2k views

DDD + POCO does this makes sense?

DDD promotes rich domain models with behavior in it, POCO naked objects without any objects in it. Is it possible to have them both combined? I have a Multi Layer Solution Core - has POCO ...
6
votes
3answers
868 views

Duplication in parallel inheritance hierarchies

Using an OO language with static typing (like Java), what are good ways to represent the following model invariant without large amounts of duplication. I have two (actually multiple) flavours of the ...
2
votes
3answers
1k views

Any examples of using Visio to document software?

I have Visio 2010 and want to learn how to use it to document software. Does anyone have examples of what Visio does well? Are there any things that Visio can do, but there are better tools for the ...
4
votes
1answer
563 views

How to deal with queries that do not return full entities in Domain Driven Design?

In my application, I have a listing of information that is deducted from a query that combines information from several entities. In itself, a very common situation. Now, the corresponding repository ...
3
votes
1answer
180 views

Can a domain specific language be used to representing the Open SRD

I am in the early stages of creating an open source C# library that would allow developers to drop in the open SRD (http://www.d20srd.org/) into an existing project. Abstracted it is a complex set of ...
10
votes
4answers
4k views

Are DDD Aggregates really a good idea in a Web Application?

I'm diving in to Domain Driven Design and some of the concepts i'm coming across make a lot of sense on the surface, but when I think about them more I have to wonder if that's really a good idea. ...
1
vote
4answers
1k views

Can an aggregate root hold references of members of another aggregate root?

I know that outside of aggregates I can't change anything inside an aggregate without passing by his root. That said I would like to know if an aggregate root can hold references of members (objects ...
12
votes
1answer
730 views

Is Domain Driven Design useful / productive for not so complex domains?

When assessing a potential project at work, I suggested that it might be advantageous to use a domain driven design approach to its object model. The project does not have an excessively complex ...
32
votes
3answers
879 views

Programming and Ubiquitous Language (DDD) in a non-English domain

I know there are some questions already here that are closely related to this subject but none of them take Ubiquitous Language as the starting point so I think that justifies this question. For ...