README.md 1.0 KB
Newer Older
1 2 3 4 5 6 7
---
layout: pattern
title: CQRS
folder: cqrs
permalink: /patterns/cqrs/
categories: Architectural
tags:
I
Ilkka Seppälä 已提交
8 9
  - Performance
  - Cloud distributed
10 11 12
---

## Intent
S
Sabiq Ihab 已提交
13
CQRS Command Query Responsibility Segregation - Separate the query side from the command side.
14

15
## Class diagram
16 17 18 19 20
![alt text](./etc/cqrs.png "CQRS")

## Applicability
Use the CQRS pattern when

I
Ilkka Seppälä 已提交
21 22 23
* You want to scale the queries and commands independently.
* You want to use different data models for queries and commands. Useful when dealing with complex domains.
* You want to use architectures like event sourcing or task based UI.
24 25 26

## Credits

S
Sabiq Ihab 已提交
27 28
* [Greg Young - CQRS, Task Based UIs, Event Sourcing agh!](http://codebetter.com/gregyoung/2010/02/16/cqrs-task-based-uis-event-sourcing-agh/)
* [Martin Fowler - CQRS](https://martinfowler.com/bliki/CQRS.html)
29
* [Oliver Wolf - CQRS for Great Good](https://www.youtube.com/watch?v=Ge53swja9Dw)
I
Ilkka Seppälä 已提交
30
* [Command and Query Responsibility Segregation (CQRS) pattern](https://docs.microsoft.com/en-us/azure/architecture/patterns/cqrs)