How to inject dependencies into the global.asax.cs
问题 How do I inject dependencies into the global.asax.cs, i.e. the MvcApplication class? Having previously used the Service Locator (anti-)pattern for dependency injection, I am trying to follow best practice advice in my latest MVC application by using an IOC container (specifically Unity.Mvc3 because it comes with an implementation of the IDependencyResolver out of the box) and constructor injection. Everything seems quite straight forward so far except for a couple of snags, one of which is in