140 likes | 563 Views
Investigating CQRS. Mark J. Miller http://www.developmentalmadness.com. Overview. Introducing CQRS Investigating SimpleCQRS framework Extending SimpleCQRS Adding IoC Replacing “storage” (Event Sourcing, Read Model) Client Ids Optimizing Serialization Guaranteed Delivery
E N D
Investigating CQRS Mark J. Miller http://www.developmentalmadness.com
Overview • Introducing CQRS • Investigating SimpleCQRS framework • Extending SimpleCQRS • Adding IoC • Replacing “storage” (Event Sourcing, Read Model) • Client Ids • Optimizing Serialization • Guaranteed Delivery • Event Store transparency (how do I look at the data?)
Introducing CQRS • Impedance Mismatch • Command-Query Responsibility Segregation • CQRS != Event Sourcing • Eventual Consistency not required (but it helps) • Idempotence and Guaranteed Delivery (At-least once) • Very DDD friendly – (Read the book)
Command/Query Responsibility Segregation Queries View Model UI Queries Commands Publish WS Input View Model Updater Validation Validation Rules DB
Extending SimpleCQRS • Adding IoC • Replacing “storage” (Event Sourcing, Read Model) • Client Ids • Optimizing Serialization • Guaranteed Delivery • Event Store transparency (how do I look at the data?)
7 6 5 4 3 2 1
6 5 snap 4 3 2 1
CQRS Samples • SimpleCQRS – Greg Young • http://github.com/gregoryyoung/m-r • Fohjin.DDD – Mark Nijhof • http://github.com/MarkNijhof/Fohjin/tree/master/Fohjin.DDD.Example/ • CQRS Kitchen – Dennis Doomen • http://thecqrskitchen.codeplex.com/
Did you mean CARS? • CQRSInfo.com • http://groups.google.com/group/dddcqrs • Greg Young - codebetter.com/blogs/gregyoung • UdiDahan – www.udidahan.com • Mark Nijhof - elegantcode.com • Jonathan Oliver - jonathan-oliver.blogspot.com • DDD: • Domain-Driven Design, Eric Evans • http://www.infoq.com/minibooks/domain-driven-design-quickly • Comb: • http://www.informit.com/articles/article.aspx?p=25862&seqNum=7 • http://sqlblog.com/blogs/alberto_ferrari/archive/2007/08/31/how-are-guids-sorted-by-sql-server.aspx