Let's take an example UI for editing Customer information. The user edits 5 fields and presses "submit". Because we're good abstractionists, we've taken the edits to the 5 fields and make them different commands (describing the edit to a particular field).
The command handlers end up setting properties on objects that are persisted with...
Hello,
Those who have read about CQS principle know that:
CQS states that every method should
either be a command that performs an
action, or a query that returns data
to the caller, but not both.
Speaking of ASP.NET MVC Actions, does CQS indicate that we shouldn't have an Action like this?
public PartialView InsertOrder(...
In wikipedia's definition of command query separation, it is stated that
More formally, methods should return a value only
if they are referentially transparent
and hence possess no side effects.
If I am issuing a command, how should I determine or report whether that command was successful, since by this definition the functi...