Applying Domain Driven Design and Patterns

I read Applying Domain-Driven Design and Patterns over the last week.

clip_image001

Nilsson synthesized thoughts from pretty much every other book in the Fowler series and then gave his own spin on creating an enterprise-read application. The book is the first that I have seen for such an ambitious goal – actually applying DDD to a real-world example. I thought he did a good job in exploring the different possibilities when confronted with design decisions. In addition, he writing style was clear and on-point.

The only problem I have with his book is that some of the patterns he selected are out of date (not his fault at the time of his writing, his fault for not releasing a new edition). For example, he spends a whole lot of time with NHibernate (Chapter 8-9), which has been eclipsed by Entity Frameworks. Also, his implementation of a validation pattern is obsolete (chapter 7) with the new constructs in .NET 4.0. I would use the validation patterns found in the Scotts’ Nerd Dinner solution. In addition, he spends a lot of time with the implementation of the query object pattern – which is LINQ to you and me now.

Finally, the separation into a Factory and Builder pattern, although still accepted in some parts of the community, is too much SOC. I believe that a single factory that is responsible for the creation (rehydration or new) and updating of a class makes much more intuitive sense.

The two patterns that I am planning to implement in the my next POC application is the State pattern and the Specification Patten. His description and implementation was a guide for me to follow. I am leaning to re-writing the Hurricane solution using these patterns.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: