The existing decorator implementation in Autofac requires decorator chains be declared in an explicit manner using named/keyed registrations. This was an intentional design decision to ensure that the correct decorators are applied in the correct order, even in the presence of dynamic registrations or those added in a late-bound manner. For better or for worse, it has become more common place in DI container implementations to imply meaning from the order that registrations are configured, and use that implication to change the behaviour of services resolved at runtime.
The dependency injection support in Service Fabric allows you to provide instances for reliable actors, stateful services, and stateless services. Instead of providing a conforming container abstraction the Service Fabric team opted to use a factory based mechanism instead. Factory methods for creating service instances are registered with the runtime via the
As Travis mentioned in his earlier blog post the road to 4.0.0 has certainly been an interesting one. This is largely in part because we got on the .NET Core train back in the early DNX days, and as a result experienced all the renames and breaking changes that come with using early bits of a new technology. It certainly highlighted to me just how much I had been taking for granted to the excellent tooling support that Visual Studio provides. There were a few points in time when the Visual Studio tooling would align with a public beta or RC version of .NET Core, but that wasn't useful to us because we had already moved on to working with the next release which was no longer compatible with that tooling. The tooling team was always playing catch up with what had already been finished and fixing things that had been broken. On the plus side I ended becoming more familiar with the new .NET Core command line tools and Visual Studio Code which is a great code editor that you can definitely be productive in.
As Travis outlined in his recent post, we've been hard at work getting Autofac ready for ASP.NET 5.0 and the new Core CLR. The 4.0.0-alpha1 release of the core library and integration for ASP.NET 5.0 are now available on NuGet. The packages can be used with Visual Studio 2015 CTP 6 and the 1.0.0-beta3 release of ASP.NET 5.0.
Currently, in the both the Web API and MVC frameworks, dependency injection support does not come into play until after the OWIN pipeline has started executing. This is simply a result of the OWIN support being added to both frameworks after their initial release. In fact, the OWIN support in MVC does not yet extend to the self hosting scenario and is limited to plugging in OWIN middleware.
I was recently asked how to best create
ServiceHost instances wired up with Autofac when using WCF Self Hosting in a Windows Service. In particular, how to do this in a dynamic way when the WCF services are defined in a separate assembly, without moving the service host configuration into the Windows Service entry point assembly.
The ASP.NET and Web Tools for Visual Studio 2013 introduced filter overrides for MVC 5 and Web API 2. This rather useful feature is only briefly mentioned in the release notes.
The following 3.1.0 packages have been pushed to NuGet:
We have pushed some minor updates to the core Autofac package and a few of the integration packages to NuGet. There is a mix of enhancements and bug fixes across the different packages. You can find all the details below.
The NuGet packages and download zips are now available for the final release of Autofac 3.0. The biggest changes since Beta 2 are the introduction of an official SignalR integration (built against the RC1 version) and plenty more documentation on the wiki (with even more on the way). The release notes below outline the changes between Beta 2 and the final release. You find details for the previous beta versions on the release notes page. Thank you to everyone who tested the beta versions and provided the team with valuable feedback. A big shout out to Travis Illig for helping make 3.0 such a great release, and to Nicholas Blumhardt for starting such an awesome open source project.