Technical patterns are filled with myths and mishaps. Quite often, this happens to CQS and CQRS.
Let’s start with these enigmatic acronyms.
CQS stands for Command Query Separation.
CQRS, Command Query Responsibility Segregation.
You can hear quite often that to use CQ(R)S:
You need two databases.
You have to use a messaging queue (e.g. RabbitMQ or Kafka).
It’s hard to apply and complicates the architecture.
You’ll be facing Eventual Consistency.
You need to do Event Sourcing.
Unfortunately, most of the material shows a skewed perspective about CQRS, not the original definition. CQRS is about separating behaviours in your architecture to writes and reads. It's about focusing on the business operations and ensuring that "writes" (so business logic) are separated from the read operations. That's not related to messaging, event sourcing, eventual consistency, etc. It's about making clear operation intentions and segregating them. I wrote longer about the common myths in my article:
During the webinar, we tackled those myths.
I showed how to start with the classical layered CRUD monolith and, step by step, go to the CQRS. I showed that you don’t need a fancy tech stack but focus on the business and slicing your architecture vertically to get more explicit and straightforward code.
See the full code in: https://github.com/oskardudycz/EventSourcing.NetCore.
Webinars:
#2 - Keep your streams short! Or how to model Event-Sourced systems efficiently
#4 - From CRUD to CQRS in practice
#6 - Alexey Zimarev - You don't need an Event Sourcing framework. Or do you?
#7 - Design and test Event-Driven projections and read models
#9 - Radek Maziarka - Modularization with Event Storming Process Level
#11 - Maciej "MJ" Jędrzejewski - Evolutionary Architecture: The What. The Why. The How.
#12 - Jeremy D. Miller: Simplify your architecture with Wolverine
#14 - Mateusz Jendza: Why Verified Credentials is the Future of Digital Identity!
#15 - Mário Bittencourt: Leveraging BPMN for Seamless Team Collaboration in Software Development
Papers We Love #1 - Sagas (Hector Garcia-Molina, Kenneth Salem)
Share this post