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)

1
vote
2answers
263 views

taxonomy of software project resourcing models

I would like to understand the impact of different resourcing models for software projects. First, I would like to identify the different resourcing approaches that are used to resource software ...
4
votes
1answer
187 views

OOP, domain models, and the user

When developing domain models, I can see two major ways of thinking about the user: The first one assumes that a program is a kind of "simulation" of what happens in the real world, and the user is ...
1
vote
2answers
208 views

Modeling an extensible Domain Driven Design project

Say that we are developing an application with modules (Sales, Accounting, Purchasing, etc). An example case here is : Sales module is the basic / primary module available, and Accounting module is ...
1
vote
2answers
157 views

DDD Proper aggregates division and getting rid of too many references

I am designing an application, which will aid designing electric installations. I went for Domain Driven Design, as the topic is complex and the application will be growing with gained knowledge. ...
0
votes
1answer
220 views

DDD, creating an aggreagate from outside the application service layer

I have a service(webservice) that is used to access to the domain logic. One of the methods of the webservice is createFoo, where Foo is my aggregate. So the class that implements the webservice's ...
4
votes
3answers
265 views

Ensuring transactional consistency with DDD

I am starting out with DDD and understand that aggregate roots are used to ensure transnational consistency. We should not modify multiple aggregates in one application service. I would like to know ...
1
vote
1answer
490 views

Entity framework and Eager loading and enterprise application with DDD aproach

We are trying to create an ASP.NET MVC 4 application using entity framework with domain driven development style pattern approach. As you can see in our part of domain layer, we have a complex design. ...
4
votes
5answers
576 views

How to model an address type in DDD?

I have an User entity that has a Set of Address where Address is a value object: class User{ ... private Set<Address> addresses; ... public setAddresses(Set<Address> ...
8
votes
2answers
409 views

Where do we put “asking the world” code when we separate computation from side effects?

According to Command-Query Separation principle, as well as Thinking in Data and DDD with Clojure presentations one should separate side effects (modifying the world) from computations and decisions, ...
1
vote
3answers
190 views

Repository query conditions, dependencies and DRY

To keep it simple, let's suppose an application which has Accounts and Users. Each account may have any number of users. There's also 3 consumers of UserRepository: An admin interface which may list ...
0
votes
1answer
750 views

How do you formulate the Domain Model in Domain Driven Design properly (Bounded Contexts, Domains)?

Say you have a few applications which deal with a few different Core Domains. The examples are made up and it's hard to put a real example with meaningful data together (concisely). In Domain Driven ...
4
votes
3answers
313 views

Architecting multi-model multi-DB ASP.NET MVC solution

I have an ASP.NET MVC 4 solution that I'm putting together, leveraging IoC and the repository pattern using Entity Framework 5. I have a new requirement to be able to pull data from a second database ...
29
votes
3answers
4k views

Rich Domain Models — how, exactly, does behavior fit in?

In the debate of Rich vs. Anemic domain models, the internet is full of philosophical advice but short on authoritative examples. The objective of this question is to find definitive guidelines and ...
6
votes
2answers
1k views

DDD Bounded Contexts & Domains?

I've been working in a relatively complex application with 10's of database tables (Aggregates, Entities/Value Objects) and applying DDD. At this point it appears to be basically DDD-Lite meaning that ...
1
vote
1answer
395 views

Applying DDD principles in a RESTish web service

I am developing an RESTish web service. I think I got the idea of the difference between aggregation and composition. Aggregation does not enforce lifecycle/scope on the objects it references. ...
-4
votes
2answers
232 views

Am I barking up the wrong tree with Scala? [closed]

Having some spare time, I've decided to learn a new programming language while developing - for fun, will never see the light of day - an insurance administration web application (insurance is the ...
1
vote
1answer
195 views

Can all business logic be decomposed as a (declarative) state diagram on simple crud operations and conditionals?

This seems an extreme question probably but I'm wondering anyhow: Can all business logic be decomposed as a (declarative) state diagram on simple crud operations and conditionals? Already a lot of ...
-2
votes
1answer
301 views

DDD/SOA Using .NET Message pattern(s) / Request Response with File Saving [closed]

I've done some research on this but I can't find more specific examples to help me with this. I'm new to SOA/Patterns in general please take it easy... :) Can you display an example of using the ...
0
votes
3answers
1k views

MVVM application architecture, where to put dependency injection configuration class, BusinessLayer and Common interfaces?

Planning my architecture for an MVVM application I come to this: MyApp.UI View MyApp.BusinessLayer ViewModel MyApp.DataAccessLayer RepositoryImplEF MyApp.DomainLayer DomainObject ...
0
votes
3answers
854 views

Auto - incremental ID in Domain Object

I read a lot about auto-incremental id (guid, interlocked.increment, ObjectIdGenerator...) but don't find nothing for my situation. In my domain model user ask to have an automatic progressive ...
7
votes
1answer
293 views

How to use BDD to unit test a compiler?

My team is writing a compiler for a domain-specific language (DSL) which will be integrated into an IDE. Right now, we are focused on the analysis phase of the compiler. We are not using any existing ...
5
votes
4answers
835 views

Refactoring jQuery spaghetti code to use DDD [closed]

Most of my client side code ends up as a long script in one file the mostly looks like this: <script> function someFunction1(){/*...*/} function someFunction2(){/*...*/} ... var ...
1
vote
1answer
570 views

Where to validate domain model rules that depend on database content?

I'm working on a system that allows Administrators to define Forms that contain Fields. The defined Forms are then used to enter data to the system. Sometimes the Forms are filled by a human via a ...
3
votes
2answers
586 views

Encapsulation in Domain Driven Design models?

I am using EF Code First and I had a model like below. public class Account { [Required] public string AccountNo { get; set; } [Required] public decimal Balance { get; set; } } I ...
1
vote
3answers
453 views

Which layer does async code belong?

I am developing an application that consumes data from an external service. The application is being implemented following a typical layered architecture with UI, Presentation, Domain and Data ...
2
votes
1answer
291 views

Need help understanding UML diagram

I'm focusing on trying to understand UML diagrams and learning to interpret them in order to implement the designs they describe. In the following diagram, I am not clear on what the implementation ...
1
vote
2answers
170 views

Determining the aggregates in this domain

I'm working on an ordering system where we receive tab delimited files that look like this (I removed most of the columns for clarity): OrderId OrderLineId BuyerName BuyerAdress ...
2
votes
1answer
930 views

Should we mock entities and value objects when doing DDD?

After reading a few articles about Newable vs Injectable objects and how these concepts relate to DDD's services, entities and value objects, I was left with some doubts about using newables in my ...
1
vote
2answers
426 views

Should the search engine return a dictionary or strongly typed objects?

I'm building a search engine using Lucene.NET / Solr.NET, and I'm wondering should search hits be returned as a dictionary or strongly typed object. public class SearchResult { public string ...
1
vote
1answer
361 views

Refactoring the shipping application code to use DDD factories

I was trying to find examples for using DDD factories and I came across the shipping application from Eric Evans' book. However when I checked the BookingService the code to create a Cargo had this ...
1
vote
1answer
154 views

Complex fetching of Domain Objects

Usually whenever I want to fetch an aggregate root by ID I just use some type of Repository::findByID(...) function Whenever I started with DDD I thought factories where just a pattern to build new ...
2
votes
2answers
450 views

NHibernate and complex domain model against a legacy database

I'm trying to refactor (actually, rewrite) an application which currently uses only stored procedures to access the database (hundreds of SPs). My goal is to use Nhibernate and follow a good design as ...
1
vote
1answer
580 views

Combining Single Page Application and DDD with a REST API

I'm creating a web application which on the client side consists of a Single Page Application (with Durandal) and on the server side an ASP.NET MVC site with a Domain Driven Design. The two are ...
2
votes
1answer
285 views

Vernon's book Implementing DDD and modeling of underlying concepts

Following questions all refer to examples presented in Implementing DDD In article we can see from Figure 6 that both BankingAccount and PayeeAccount represent the same underlying concept of ...
3
votes
2answers
397 views

How far to go with Domain Driven Design?

I've read a little about domain driven design and the usage of a rich domain model, as described by Martin Fowler, and I've decided to put it in practice in a personal project, instead of using ...
3
votes
1answer
130 views

Ubiquitous Language and Custom types

Note that my question is referring to those attributes that even on their own already represent a concept ( ie on their own provide a cohesive meaning ). Thus such attribute needs no additional ...
3
votes
1answer
211 views

Wouldn't Layer Supertype pattern corrupt our domain model?

a) To my knowledge Domain Objects should for the most part be oblivious to technical aspects of a design. Since I view class inheritance as being a technical solution, wouldn't introducing a Layer ...
0
votes
2answers
241 views

In OnionArchitecture can UI talks directly to datastore or not?

I'm fan of onion architecture but looking for some relaxing solutions in some areas. First of all I was thinking about communicating directly from UI (from controller in mvc) to data on the read ...
0
votes
3answers
199 views

How to handle complex conditions? [duplicate]

We are working on project where we have to manage these conditions. i.e.: A User can save an order under these conditions: User has permission "SaveOrder" Order is in state "shipped" Online Shop is ...
1
vote
2answers
2k views

Anemic Domain Model vs. DDD by definition example(s)?

What is an example of "Business Logic" that should reside in the DomainModel i.e. inside an Entity instead of inside a (Domain) Service, as well as some example logic that should be in a service. ...
2
votes
1answer
856 views

DDD/SOA in (.NET) MVC and Message pattern(s) / Request Response

We're currently considering whether it makes sense (or if the benefits are worth the added code) to introduce a Message based pattern (such as Request Response) into a Domain Driven Design / Service ...
3
votes
1answer
101 views

Handling ground-breaking changes in a production system - Insert intermediate level Management object

As our client request, we are proceeding to change the base of our system. We already have the following structure: A class has many students. (simple typical one - to - many) Now we must change ...
0
votes
1answer
164 views

Shouldn't Location be a Value Object?

Eric Evan's DDD book, Cargo Shipping Example, pg. 168: Location Two places with the same name are not the same. Latitude and longitude could provide a unique key, but probably not a very ...
3
votes
2answers
297 views

Single Responsibility principle VS KISS principle

Let's assume the modeling of User model in a context of a social network. User concept is composed of two notions: Authentication elements like userName/Password/Email etc... Extra data information ...
7
votes
3answers
787 views

Is Domain Entity violating Single Responsibility Principle?

Single responsibility ( reason to change ) of an entity should be to uniquely identify itself, in other words, its responsibility is to be findable. Eric Evan's DDD book, pg. 93: most basic ...
2
votes
2answers
330 views

DDD - Domain Object calling a web service

Is it ok to call a webservice from a Domain object?. As I write the question I am thinking that you should never do that, as it is poor design, but the situation is the following: I have a domain ...
5
votes
1answer
1k views

Unique Value Object vs Entity

Trying to convert some entities into value objects I am stuck in a case where what seems a value object must be unique within an aggregate. Suppose we have a Movie entity which makes the root of an ...
1
vote
1answer
130 views

Entites in Invalid State

I'm looking into developing my entities so that they cannot be in an invalid state. In particular I'm starting with my Customer entity. This would have fields like: Title (enum) FirstName (string) ...
4
votes
2answers
364 views

A design decision in composition or aggregation

I've recently had doubts about some design decisions that I frequently make, so this time I decided to take some time and try to analyze it to find the best solution. I will describe a simple scenario ...
1
vote
2answers
471 views

Converting Business Process Maps into Software

I am fairly new to web application development. I have defined my problem domain through talking to various stakeholders and putting a process map together - basically a flow chart showing the ...