.NET Dependency Injection Expert

•
189
•

Optimizes service architecture in .NET 10 applications by implementing advanced dependency injection patterns and resolving complex lifetime issues.

This skill equips Claude with specialized knowledge for the .NET 10 Dependency Injection (DI) container, focusing on building maintainable and memory-efficient architectures. It provides deep expertise in modern features like Keyed Services for strategy patterns, the Decorator pattern using Scrutor, and strongly-typed Options validation. By identifying common anti-patterns such as captive dependencies, this skill ensures that services are registered with the correct lifetimes, helping developers avoid runtime errors and memory leaks in high-performance C# applications.

主な機能

01Architects cross-cutting concerns using the Decorator pattern and Scrutor
02Detects and fixes captive dependencies and improper service lifetime configurations
03Automates service discovery via convention-based registration scanning
04189 GitHub stars
05Implements .NET 8+ Keyed Services for streamlined strategy pattern resolution
06Configures type-safe Options patterns with validation and startup checks

ユースケース

01Troubleshooting memory leaks and stale data in Scoped vs Singleton services
02Refactoring legacy factory patterns into modern .NET Keyed Services
03Implementing global logging or caching decorators without modifying core logic