IIS7 dynamic_compression_not_success Reason 12
Posted
by Peter Oehlert
on Server Fault
See other posts from Server Fault
or by Peter Oehlert
Published on 2010-03-22T22:42:52Z
Indexed on
2010/03/22
22:51 UTC
Read the original article
Hit count: 840
So, I'm a bit of an IIS7 n00b but I've used most of the old IIS systems going back to 3. I'm trying to turn on dynamic compression and it's working, mostly. It doesn't work for my ADO.Net Data Service (Astoria) requests, batched or not.
I found the freb tracing which was really helpful. And what I come up with unbatched requests is that it returns Reason Code 12, NO_MATCHING_CONTENT_TYPE. OK, so I don't have the matching mime type specified, that's easy.
Except this is what I have in my web.config (which I think is correct, but maybe not).
<httpCompression dynamicCompressionDisableCpuUsage="100"
dynamicCompressionEnableCpuUsage="100"
noCompressionForHttp10="false"
noCompressionForProxies="false"
noCompressionForRange="false"
sendCacheHeaders="true"
staticCompressionDisableCpuUsage="100"
staticCompressionEnableCpuUsage="100">
<dynamicTypes>
<clear/>
<add mimeType="*/*"
enabled="true" />
</dynamicTypes>
<staticTypes>
<clear/>
<add mimeType="*/*"
enabled="true" />
</staticTypes>
</httpCompression>
<urlCompression doDynamicCompression="true"
doStaticCompression="true"
dynamicCompressionBeforeCache="false" />
Now I think that this means it should compress any request that includes the Accept:Gzip header. I'd love to know what others might think here.
My fiddler trace:
GET /SecurityDataService.svc/GetCurrentAccount HTTP/1.1
Accept-Charset: UTF-8
Accept-Language: en-us
dataserviceversion: 1.0;Silverlight
Accept: application/atom+xml,application/xml
maxdataserviceversion: 1.0;Silverlight
Referer: http://sdev03/apptestpage.aspx
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; WOW64; Trident/4.0; SLCC1; .NET CLR 2.0.50727; .NET CLR 3.5.21022; .NET CLR 3.5.30729; InfoPath.2; .NET CLR 3.0.30729; OfficeLiveConnector.1.4; OfficeLivePatch.1.3)
Host: sdev03
Connection: Keep-Alive
Cookie: .ASPXAUTH=<snip>
HTTP/1.1 200 OK
Cache-Control: no-cache
Content-Type: application/atom+xml;charset=utf-8
Server: Microsoft-IIS/7.0
DataServiceVersion: 1.0;
X-AspNet-Version: 2.0.50727
X-Powered-By: ASP.NET
Date: Mon, 22 Mar 2010 22:29:06 GMT
Content-Length: 2726
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
*** <snip> removed ***
© Server Fault or respective owner