Images in this post missing? We recently lost them in a site migration. We're working to restore these as you read this. Should you need an image in an emergency, please contact us at
DDD: Sample Application First Steps

As mentioned in my last post, the DDD Parcel Service is opening up for business soon. Also as mentioned, the first thing I did was to grab my Domain Expert and start some initial conversations around the first areas I am approaching – the Booking service.

All of the documentation I am generating is to be included in the SVN (SVN public access to follow in the near future please be patient), so hopefully as the design evolves, and the UL and model change with it, this will be evident to some degree within that documentation. I’m going to get boring again, but the documentation is far more important in DDD than many of us Agilists would traditionally like – at least the resulting artifacts are, so it is important to me to show in the documentation why I am making code decisions.

The Tools

I am primarily using two nifty tools at the moment for capturing the information I need – the ever excellent MS Office OneNote 2007, and a new addition to my arsenal – Balsamiq

OneNote provides and excellent dumping group for notes and ideas as they get fired at me, and quickly allows me to form those into some coherent format.

But the true star of this process so far is Balsamiq.

User Interface Lead Design?

I wanted to validate the User Stories I had extracted from my DE, by showing how these could take form within the UI. To some this may seem like heresy, after all DDD is all about the domain right?

Well, I actually see DDD as being lead by a combination of the Ubiquitous Language on one hand, and the User Stories and Use Cases on the other.

Extracting the UL from the initial User Stories was part of the first task, but validation of these was far easier to do with some visual aid – so a mockup was needed. I could have done this in HTML, but luckily Balsamiq recently became a partner and I was keen to try it in anger on a “real” project.

Mockups Made Simple

The initial user story we worked out was around booking a parcel delivery, and after some discussion we got to:

The Customer wants to be able to send a Consignment , so they log onto the Client website to Book a Delivery:

  1. They choose their Pickup Location
  2. They choose their Destination
  3. They choose their required Pickup Date
  4. They choose their Delivery Window options
  5. They choose the Consignment details
  6. They choose any Special Instructions
  7. They receive a Quotation for delivery if the system is capable of quoting, or a Callback for a Non-Standard Consignment
  8. If they wish to proceed they click Confirm

Firing up Balsamiq was quick, and within a few minutes of drag and drop, and a few moments of cursing when I kept forgetting to lock items, I had a good starting point for the UI:

Booking a new delivery - step 1

Less than 30 minutes later I had the whole story mocked up and ready to validate. Not unsurprisingly, it was really easy for my DE to look at these screens and envisage the process in action. This lead to a few changes in the UL, and a couple of extra questions arising – exactly the kind of validation that was needed. Had I done this in HTML or code I could have spent a good many hours doing something not half as representative.

If you want to see the initial modelling you can download them as PDFs here:

Kudos to both OneNote and Balsamiq for excellent applications to let me gather and organise the results of my initial conversations! Tags: ,,,

Posted 03-09-2009 5:39 PM by Jak Charlton



DotNetShoutout wrote DDD: Sample Application First Steps - Casey Charlton - Insane World
on 03-09-2009 3:46 PM

Thank you for submitting this cool story - Trackback from DotNetShoutout

Reflective Perspective - Chris Alcock » The Morning Brew #303 wrote Reflective Perspective - Chris Alcock » The Morning Brew #303
on 03-10-2009 3:02 AM

Pingback from  Reflective Perspective - Chris Alcock  » The Morning Brew #303

Gabriel Schenker wrote re: DDD: Sample Application First Steps
on 03-10-2009 3:32 AM

I am following your series about DDD with great interest. Now finally you "put the meat onto the bone". That is you go from theory to practice. Most books stop at the theory and only provide very basic implementations. You show the whole process like finding the user stories and establishing the UL  together with the DE... not to forget what tools you use.

Your tool set shows to me: once again simplicity is the way to go!

Karsten wrote re: DDD: Sample Application First Steps
on 03-10-2009 4:42 AM

Just wanted to say, that I'm following the series and is quite excited about it :-)

Jak Charlton wrote re: DDD: Sample Application First Steps
on 03-10-2009 4:58 AM

Karsten, Gabriel

Thanks to both for your enthusiasm and interest


I'm going to borrow some of your NH code later in the series - precisely because it is nice, simple, expressive and to the point ... just how I like code to be wrote infoDose #21 (10th Mar - 15th Mar)
on 03-16-2009 1:09 AM infoDose #21 (10th Mar - 15th Mar)

The reality of UI mock-ups and DDD « wrote The reality of UI mock-ups and DDD «
on 03-19-2009 2:51 AM

Pingback from  The reality of UI mock-ups and DDD «

Lovell wrote re: DDD: Sample Application First Steps
on 01-03-2010 2:42 PM

The PDF Link has a SQL conn string exception. As a matter of fact, all of your PDF links in the DDD series pop that exception.

About The CodeBetter.Com Blog Network
CodeBetter.Com FAQ

Our Mission

Advertisers should contact Brendan

Google Reader or Homepage Latest Items
Add to My Yahoo!
Subscribe with Bloglines
Subscribe in NewsGator Online
Subscribe with myFeedster
Add to My AOL
Furl Latest Items
Subscribe in Rojo

Member Projects
DimeCasts.Net - Derik Whittaker

Friends of
Red-Gate Tools For SQL and .NET


SmartInspect .NET Logging
NGEDIT: ViEmu and Codekana
NHibernate Profiler
Balsamiq Mockups
JetBrains - ReSharper
Web Sequence Diagrams
Ducksboard<-- NEW Friend!


Site Copyright © 2007 CodeBetter.Com
Content Copyright Individual Bloggers


Community Server (Commercial Edition)