CleanArchitecture-Template
CleanArchitecture-Template copied to clipboard
This stands as a comprehensive solution template that embodies the principles of Clean Architecture, seamlessly integrated with the prowess of CQRS implementation, all within the ASP.NET Core framewor...
CleanArchitecture-Template
This is a solution template for Clean Architecture and CQRS implementation with ASP.NET Core
Give a Star! ⭐
If you like or are using this project to learn or start your solution, please give it a star. Thanks!
The easiest way to create your project
1. Open CMD
2. Run
> dotnet new --install ASPNETCleanTemplate.nuspec::3.1.0
3. Create an empty folder for your solution and cd into it.
4. Run the following code and enter your project name instead of MyNewCleanTemplate
> dotnet new ASPNETCleanTemplate -n MyNewCleanTemplate
For Database Migration:
First:
Set default project to Persistence
Second:
Run following code in Package Manager Console
> Update-Database -Context AppDbContext
HealthCheck
use the following url to open health check admin ui
https://Url:Port/healthchecks-ui
Technologies used:
- ASP.NET Core
- Entity Framework Core
- MediatR
- Swagger
- Redis (for distributed caching)
- Jwt Token Authentication
- Custom Asp.Net Identity
- Api Versioning
- FluentValidation
- PolyCache (for caching)
- Serilog
- Elasticsearch (for writing Logs)
- AutoMapper
- Docker
Software Development Best Practices and Design Principles used:
- Clean Architecture
- Clean Code
- CQRS
- Authentication and Authorization
- Distributed caching
- Solid Principles
- Separate ReadOnly and Write DbContext
- Separate ReadOnly and Write Repository
- REST API Naming Conventions
- Use multiple environments in ASP.NET Core (Development,Production,Staging,etc)
- Modular Design
- Custom Exceptions
- Custom Exception Handling
- PipelineBehavior for Validation and Performance tracking.
Read More
- https://virgool.io/@ahmadpooromid/%D9%85%D9%81%D9%87%D9%88%D9%85-%D9%88-%D9%BE%DB%8C%D8%A7%D8%AF%D9%87-%D8%B3%D8%A7%D8%B2%DB%8C-scalability-%D8%AF%D8%B1-cqrs-peixkgrbdgff
- https://medium.com/@omid-ahmadpour/clean-architecture-template-with-net-and-its-importance-e5b3b97a6e48