This is a boiler plate for PayBright microservices. It can be used as a reference or taken from as you create the repository. Please esure your own configurations for proper indexing etc if you're to use EF core.
-
Logical seperations:
- Api.
- Business.
- Domain.
- Infrastructure.
-
Clean Configurations.
-
MedatR
-
Global Filters.
-
Swagger.
-
Fluent Validation.
-
Design Time Configurations (including cmds)
-
Buiness seedwork / Foundations
-
Domain seedwork / Foundations
-
Infrastructure seedwork.
-
Docker Support.
-
Environment variables.
-
DDD
- Abstract Entity
- IBusinessRule
- Generic Repository (Handy for Aggregates)
- Exception Handling.
- BaseHttpClient (Mostly done)
- RestSharp/XML
- RestSharp/JSON
- Test Abstractions (Ties into MediatR.
- MediatR abstractions
- Abstract IRequestHandler
- Abstract IRequest
- ICommandHandler : IRequestHandler
- IQueryHandler : IRequestHandler
- Default Github Workflows.
- Sql Connection Factory.
- Dapper abstractions (needed for read / write ORM seperations)
- Showcase branch (see the abstractions implemented)
- Remove current showcase code (demo reasons only)
- Automapper.
- Global exception handling?
- Transaction control?
- Entity cascades?
- CQRS - https://martinfowler.com/bliki/CQRS.html
- Microservice/DDD - Martin Fowler
- Clean Code - Uncle Bob
- EF Core - Training courses
- Transactional rollback - Just utilize
- Exception flow handling - https://enterprisecraftsmanship.com/posts/cqrs-exception-handling/
- GUID vs ID - https://blog.codinghorror.com/primary-keys-ids-versus-guids/
- Coding standards - Mike McCann released this in April
- Design time factory - https://blog.tonysneed.com/2018/12/20/idesigntimedbcontextfactory-and-dependency-injection-a-love-story/ (simplified)
- Architectural Blue Print - Mike McCann released
- Generic Repository Pattern - Knowing when to use one is whats key https://www.programmingwithwolfgang.com/repository-pattern-net-core/ (don't include repeated try catch)
- Logical seperation - https://docs.microsoft.com/en-us/dotnet/architecture/microservices/microservice-ddd-cqrs-patterns/ddd-oriented-microservice (Elaborated)
- Aggregate Service Pattern - https://autofaccn.readthedocs.io/en/latest/advanced/aggregate-services.html
- Aggregate Models - https://martinfowler.com/bliki/DDD_Aggregate.html
- MediatR, when and when not to?- https://codeopinion.com/why-use-mediatr-3-reasons-why-and-1-reason-not/
- Healthcheck on microservice? - https://medium.com/it-dead-inside/implementing-health-checks-in-asp-net-core-a8331d16a180
- Validation tiers - https://www.infoq.com/articles/ddd-business-rules/
- When should we use in memory testing? Only for testing code itself in unit testing some function NEVER for integration tests.
- https://docs.microsoft.com/en-us/ef/core/testing/
- Preserving encapsulation in ef core - Just look at Vladimir Khorikovs work
- https://enterprisecraftsmanship.com/posts/new-online-course-ddd-and-ef-core/
- EF Core & Dapper? Our Infra should be capable of using both, without ever crossing concerns. Shawn Wildermuth has a bunch of vids on this.
- Service Collection Extension? https://dotnetcoretutorials.com/2017/01/24/servicecollection-extension-pattern/ (Good but not great, we have made some improvements)
- Docker? Defined by Brian
- Github Actions? Defined by Brian
- Single deployments (design time factory, health checks) - Brian
- Exception Handling - https://andrewlock.net/handling-web-api-exceptions-with-problemdetails-middleware/