# matthewrenze/clean-architecture-demo

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/matthewrenze-clean-architecture-demo).**

1,217 stars · 501 forks · C# · BSD-3-Clause

## Links

- GitHub: https://github.com/matthewrenze/clean-architecture-demo
- awesome-repositories: https://awesome-repositories.com/repository/matthewrenze-clean-architecture-demo.md

## Description

This project serves as a reference implementation for applying clean architecture principles within a C# environment. It demonstrates how to structure enterprise applications by organizing code into concentric, independent layers that isolate core business logic from external infrastructure, frameworks, and database concerns.

The codebase illustrates the application of domain-driven design to center software logic around business entities and rules. It utilizes interface-based decoupling and dependency inversion to ensure that high-level policies remain unaware of low-level implementation details, facilitating long-term maintainability and testability.

To manage data access, the project employs the repository pattern to abstract storage technologies. This approach decouples the domain layer from specific persistence mechanisms, allowing for the replacement of data providers without requiring modifications to the core application logic. Dependency injection is used throughout to manage object lifecycles and component wiring.

## Tags

### Software Engineering & Architecture

- [Clean Architecture Implementations](https://awesome-repositories.com/f/software-engineering-architecture/java-application-architecture/clean-architecture-implementations.md) — Demonstrates clean architecture principles by organizing code into concentric layers that isolate business logic. ([source](https://github.com/matthewrenze/clean-architecture-demo/tree/net45))
- [Dependency Inversion Patterns](https://awesome-repositories.com/f/software-engineering-architecture/project-management-governance/dependency-boundary-enforcers/dependency-inversion-patterns.md) — Implements dependency inversion to ensure business logic remains independent of infrastructure and database concerns.
- [Domain-Driven Designs](https://awesome-repositories.com/f/software-engineering-architecture/software-architecture/architectural-patterns/abstraction-domain-modeling/domain-driven-designs.md) — Structures core application logic around business entities and rules to align architecture with business domains.
- [Interface-Based Decoupling](https://awesome-repositories.com/f/software-engineering-architecture/component-abstractions/interface-based-decoupling.md) — Uses abstract interfaces to decouple high-level policies from low-level implementation details.
- [Database Abstraction Layers](https://awesome-repositories.com/f/software-engineering-architecture/database-abstraction-layers.md) — Implements repository patterns to provide a unified way to interact with storage systems without coupling to specific backends.
- [Dependency Injection Containers](https://awesome-repositories.com/f/software-engineering-architecture/dependency-injection-containers.md) — Provides a structured container for managing object lifecycles and dependency resolution.
- [Architecture Reference Implementations](https://awesome-repositories.com/f/software-engineering-architecture/open-source-projects/architecture-reference-implementations.md) — Serves as a reference implementation demonstrating architectural best practices for decoupling business logic.
- [Software Architecture Design](https://awesome-repositories.com/f/software-engineering-architecture/software-architecture-design.md) — Structures complex applications into independent layers to isolate business rules from infrastructure concerns.

### Part of an Awesome List

- [Domain Driven Design](https://awesome-repositories.com/f/awesome-lists/learning/domain-driven-design.md) — Provides a pedagogical example of structuring application logic around business entities and rules.

### Data & Databases

- [Repository Patterns](https://awesome-repositories.com/f/data-databases/repository-patterns.md) — Implements repository patterns to encapsulate data access logic and decouple the domain from persistence.
- [Repository Pattern with Swap Support](https://awesome-repositories.com/f/data-databases/repository-patterns/repository-pattern-with-swap-support.md) — Abstracts database interactions behind repository interfaces to allow storage technology swaps without logic changes. ([source](https://github.com/matthewrenze/clean-architecture-demo#readme))

### DevOps & Infrastructure

- [Dependency Injection Containers](https://awesome-repositories.com/f/devops-infrastructure/dependency-management/dependency-injection-containers.md) — Manages object lifecycles and wiring at runtime to ensure components remain loosely coupled and testable.

### Networking & Communication

- [Repository Pattern Abstractions](https://awesome-repositories.com/f/networking-communication/protocol-abstraction-layers/repository-pattern-abstractions.md) — Abstracts data access logic into repository interfaces to decouple domain entities from persistence details.
