Requests for static files are hitting the managed code in ASP.NET MVC3
问题 Creating custom IHttpModules, I have realized that the requests for static files (e.g.: .css and .js files) are hitting the managed modules. Probably pictures have the same problem. Shouldn't IIS bypass ASP.NET for files that exists in the filesystem? For example: public class MyModule:IHttpModule { public void Dispose(){ } public void Init(HttpApplication context) { context.BeginRequest += (o, e) => Debug.Print("Request: " + HttpContext.Current.Request.RawUrl); } } And I declare it this way: