I use Azure and IIS 7.5 to serve my web application, but I do not use .NET.
I am trying to override the default cache value for my static files, but it looks like IIS 7.5 adds cache, no matter what I specify.
My approot / web.config file looks like this:
<?xml version="1.0"?> <configuration> <system.webServer> ... <staticContent> <clientCache cacheControlCustom="public" cacheControlMode="UseMaxAge" cacheControlMaxAge="30.00:00:00" /> </staticContent> ... </system.webServer> </configuration>
and my answer headers:
Accept-Ranges:bytes Access-Control-Allow-Origin:* Cache-Control:no-cache,public,max-age=2592000 Content-Encoding:gzip Content-Length:4309 Content-Type:application/x-javascript Date:Mon, 10 Sep 2012 14:42:07 GMT ETag:"8ccd2f95a8fcd1:0" Last-Modified:Mon, 10 Sep 2012 13:48:36 GMT Server:Microsoft-IIS/7.5 Vary:Accept-Encoding X-Powered-By:ASP.NET
I have an additional web.config file in one of the subfolders, but this does not override any clientCache values.
Does anyone know why IIS adds cache?
Thanks!
source share