dotnet-backend-patterns

Provide ASP.NET Core backend patterns covering DI, EF Core, Dapper, and caching.

Updated Mar 18, 2026
One-click install
npx skills add https://github.com/ekremmkasap/jarvis --skill dotnet-backend-patterns-ekremmkasap
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dotnet-backend-patterns
Source: https://github.com/ekremmkasap/jarvis/tree/main/server/agent_prompts/wshobson/plugins/dotnet-contribution/skills/dotnet-backend-patterns
Command: npx skills add https://github.com/ekremmkasap/jarvis --skill dotnet-backend-patterns-ekremmkasap

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Patterns and practices for building robust .NET backends, helping teams avoid architectural drift and boilerplate.

Core Features & Use Cases

  • Clean Architecture: structuring Domain, Application, Infrastructure, and API layers for maintainability, testability, and scalable growth.
  • Dependency Injection and Async: promoting decoupled services, DI lifetimes, and consistent async code for responsive systems.
  • Data Access & Configuration: combining EF Core, Dapper, IOptions pattern, caching strategies, and testing with xUnit to deliver reliable APIs.

Quick Start

Adopt these patterns to scaffold a well-architected ASP.NET Core project with DI, clean boundaries, and testable data access.

Frequently Asked Questions about dotnet-backend-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I structure a .NET backend using clean architecture?

Structure a .NET backend using clean architecture by separating Domain, Application, Infrastructure, and API layers to ensure maintainability, testability, and scalable growth. This layout prevents architectural drift and reduces boilerplate.

What is the best way to manage dependency injection lifetimes in ASP.NET Core?

Manage dependency injection in ASP.NET Core by configuring DI registrations with appropriate lifetimes to promote decoupled services. Using consistent async code alongside DI ensures your backend systems remain responsive and scalable.

How do I combine EF Core and Dapper for data access in ASP.NET Core?

Combine EF Core and Dapper for data access in ASP.NET Core by applying repository patterns and caching strategies. This approach delivers reliable APIs while maintaining clean architectural boundaries and testable data access layers.

Do I need the IOptions pattern for configuration in scalable .NET backends?

You need the IOptions pattern for configuration in scalable .NET backends to strongly type settings and manage configurations reliably. Implementing Options patterns alongside caching strategies ensures robust enterprise application behavior.

Can I use xUnit for testing ASP.NET Core clean architecture projects?

You can use xUnit for testing ASP.NET Core clean architecture projects to verify domain logic and data access boundaries. Testing with xUnit ensures your decoupled services, DI registrations, and async patterns deliver reliable APIs.

Why does architectural drift happen in .NET backend applications?

Architectural drift happens in .NET backend applications when teams lack proven backend patterns and templates, leading to inconsistent layering and boilerplate. Adopting clean architecture boundaries and repository patterns prevents this drift.