src/Clean.Architecture.Infrastructure/README.md
In Clean Architecture, Infrastructure concerns are kept separate from the core business rules (or domain model in DDD).
The only project that should have code concerned with EF, Files, Email, Web Services, Azure/AWS/GCP, etc is Infrastructure.
Infrastructure should depend on Core (and, optionally, Use Cases) where abstractions (interfaces) exist.
Infrastructure classes implement interfaces found in the Core (Use Cases) project(s).
These implementations are wired up at startup using DI.
In this case using Microsoft.Extensions.DependencyInjection and extension methods defined in the project.
This project supports both SQL Server and SQLite:
The InfrastructureServiceExtensions.AddInfrastructureServices() method automatically detects which connection string is available and configures the appropriate database provider.
Need help? Check out the larger sample here: https://github.com/ardalis/CleanArchitecture/tree/main/sample
Still need help? Contact us at https://nimblepros.com