Skip to content
geoffreysmith edited this page Jun 1, 2011 · 11 revisions

Recipe #003 - Using Commands

Overview

Inspiration: CQRS a la Greg Young

Lets first consider what would normally happen after receiving a DTO; the user would make changes to the data and save this >back on the DTO. This DTO then gets shipped back to the back-end, converted into an entity and the ORM will make sure that >the changes are persisted into the database.

This would result in loosing some very valuable information; the Why did this change happen? You completely loose the intent >the user had when he changed the data, and this is one of the things Greg’s implementation of CQRS is solving.

Example Implementation

Clone this wiki locally