AddressBook API solution is built on Onion Architecture with all essential feature using .NET Core!
Trello board for user stories can be found here: https://trello.com/b/pHCmBh1R/addressbook
- Onion Architecture
- About the project
- Getting started
- Features available in this project
- Project description
- License used
- Contact
Onion Architecture was introduced by Jeffrey Palermo to provide a better way to build applications in perspective of better testability, maintainability, and dependability on the infrastructures like databases and services
Onion, Clean or Hexagonal architecture: it's all the same. Which is built on Domain-Driven Desgin approach.
Domain in center and building layer top of it. You can call it as Domain-centric Architecture too.
- It's all the same (Domain centeric architecture) - Mark Seemann
- Onion Architecture by Jeffrey Palermo
- Clean Architecture by Robert C. Martin (Uncle Bob)
- Hexagonal Architecture by Dr. Alistair Cockburn
AddressBook API solution is built on Onion Architecture with all essential feature using .NET Core.
Plese run the script file "InitialScript" under documents\scripts to create your database
Swagger UI
This addressbook api contains following features.
- Application is implemented on Onion architecture
- API
- Entityframework Core
- Expection handling
- Automapper
- Unit testing via NUnit & Nsubstitute for mocking
- Integration testing via NUnit
- Versioning
- Swagger
- CQRS Pattern
we can see that all the Layers are dependent only on the Core Layers
Domain layer
Domain Layers (Core layer) is implemented in center and never depends on any other layer. Therefore, what we do is that we create interfaces to Persistence layer and these interfaces get implemented in the external layers. This is also known and DIP or Dependency Inversion Principle
Persistence layer
In Persistence layer where we implement reposistory design pattern. In our project, we have implement Entityframework which already implements a repository design pattern.
Service layer
Service layer (or also called as Application layer) where we can implement business logic. For OLAP/OLTP process, we can implement CQRS design pattern. In our project, we have implemented CQRS design pattern on top of Mediator design pattern via MediatR libraries
Presentation Layer
This is an angular app found under client folder.
See the contents of the LICENSE file for details
Having any issues or troubles getting started? Drop a mail to zuluchs@gmail.com. Always happy to help.
I do coding for fun during leisure time, but I have to pay the bills, so I also work for money :P