I'm trying to add a per-request DI scope (Autofac) to my web server. I need access to the HttpContext at the moment I'm registering the controller factory, just so I can store the scope in IHttpContext.Items and retrieve/dispose it by the end of the request. Is there any way to achieve such thing?
Hello,
I'm trying to add a per-request DI scope (Autofac) to my web server. I need access to the HttpContext at the moment I'm registering the controller factory, just so I can store the scope in IHttpContext.Items and retrieve/dispose it by the end of the request. Is there any way to achieve such thing?