Cloud Native - Clean Architecture template, for ASP.NET 9 Web API, powered by .NET Aspire and DAPR
Component | Badge |
---|---|
Build Status | |
Nuget Version | |
Security Score Card |
Install the template
dotnet new install CloudNative.CleanArchitecture.Template
To create a new solution
dotnet new cn-ca -n MyCloudNativeApi
Once you clone the solution, open with Visual Studio Code
Install the extension - Polyglot Notebooks, better to install all recommended extensions, suggested by VS Code, when you open the workspace
The documents under docs
directory would be a good start
To build and deploy the project, follow the interactive notebooks under build
and deployment
directories.
This sample demonstrates how to use .NET Aspire with Dapr sidecars to connect multiple services through event-driven communication.
- ServiceA: Publishes an event to a Dapr pub/sub component.
- ServiceB: Subscribes to ServiceA’s topic, processes the event, and publishes a new one.
- ServiceC: Subscribes to ServiceB’s topic and handles the final event.
- Dapr Components: Each service runs with its own Dapr sidecar, which provides access to pub/sub, state store, and other building blocks.