Tags

#dependency-injection
dependency-injection

1stories
6 d agolatest
PostSharp 2027.0
Aspects get DI services
PMMetalama / PostSharp Blog Gaël Fraiteur 6 d ago

PostSharp 2027.0 lets aspects receive services through constructor injection

PostSharp 2027.0 lets aspects request services from the dependency injection container. The build adds those services as constructor parameters of the enhanced class, so aspects no longer need a global service locator. Legacy code can migrate gradually, and PostSharp Caching can take its backend from the container too.

Feedback

Found a bug or have an idea? Your message lands straight in my inbox.

Type of message