configurationweb-configcassini

Prevent MS Web Development Server (Cassini) from running HttpModules for static content requests


IIS7 supports this by using <system.webServer> configuration element to set module's preCondition="managedHandler" attribute.

Since Cassini is a managed server it serves requests in a similar way as IIS7 does. All requests are handled by managed code. By similar I mean it executes HttpModules for every single request even if it's static content (scripts, style sheets, images etc.).

It also appears that Cassini ignores <system.webServer> configuration settings.

Q: Is it possible to either force Cassini not to execute complete pipeline for static content or to obey <system.webServer> settings?


Solution

  • No it's not. Which is why testing against IIS is always a good idea :)