Command Query Separation (CQS) for .NET Framework and .NET Standard
- Build services that separate the responsibility of commands and queries
- Focus on implementing the handlers for commands and queries
- Create APIs with less boilerplate code
Available for:
🌐 ASP.NET Web API 2
🌐 ASP.NET Core
⚡ AWS Lambda
⚡ Azure Functions
Command Query Separation?
Queries: Return a result and do not change the observable state of the system (are free of side effects).
Commands: Change the state of a system but do not return a value.
In other words:
- Commands
- Writes (Create, Update, Delete) data
- Queries
- Reads and returns data
Inspired by:
- https://cuttingedge.it/blogs/steven/pivot/entry.php?id=91
- https://cuttingedge.it/blogs/steven/pivot/entry.php?id=92
README | Platform | NuGet | Sample |
---|---|---|---|
CommandQuery | .NET Framework and .NET Standard | CommandQuery.Sample.Contracts , CommandQuery.Sample.Handlers |
|
CommandQuery.AspNet.WebApi | ASP.NET Web API 2 | CommandQuery.Sample.AspNet.WebApi |
|
CommandQuery.AspNetCore | ASP.NET Core | CommandQuery.Sample.AspNetCore |
|
CommandQuery.AWSLambda | AWS Lambda | CommandQuery.Sample.AWSLambda |
|
CommandQuery.AzureFunctions | Azure Functions | Vs1 , Vs2 , VsCode1 , VsCode2 |
|
CommandQuery.Client | .NET Framework and .NET Standard | CommandQuery.Sample.Client |