Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Try googling around for "cqrs". There are many ideas on how to do exactly this effectively.

All it takes is to swap "write" operation with "event" entity (all is state). Combine that with intention revealing commands (customer_died instead of delete from customers where id=1) and you hit jackpot.

End result is nice stream of events which is ultimate source of truth and enables crazy queries you never thought you would ever need http://abdullin.com/journal/2010/6/3/time-machines-should-su...



This is quite interesting. In practice though, the lags between command/query models when the datastores are different(almost always, for large data) becomes a real concern


Pardon my pedantry, but CQRS doesn't necessitate eventual consistency. Denormalization of domain events into can happen synchronously. It all depends on the needs of the project. If the project information architecture and processes can support a degree of latency (which is implicit in almost any technology providing static screens anyway), then the performance gains of eventual consistency can be realized.

A good, nuanced explanation of CQRS is here: http://codeofrob.com/entries/cqrs-is-too-complicated.html




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: