O'Reilly logo

NHibernate 3 Beginner's Guide by Gabriel N. Schenker

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using one model for read and write operations

In Chapter 3, Creating a Model we have introduced the concept of a domain model. In the code samples of all subsequent chapters, we have used this domain to write or update data, as well as to read data from the database. This makes sense as long as the domain is of limited complexity or the solution we build is merely a forms-over-data type application.

If, on the other hand, our domain is very complex then this approach quickly reaches its limits.

CQRS

The CQRS pattern has been quite successful to address and solve the problem of a single and overly complex domain which is used for read and write operations. When using the CQRS pattern the domain model is exclusively used for write operations. All read ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required