COM pression不工作 [英] Compression is not working
问题描述
我需要COM preSS我的数据导出网站的所有动态内容。结果
我试过很多方法,没有什么作品。 Chrome浏览器显示的内容是不是COM pressed和内容编码标头不是present。
I need to compress all dynamic content of my data export site.
I've tried numerous ways, nothing works. Chrome shows that content is not compressed and "Content-Encoding" header is not present.
试图做这样的作为最后的手段方法(编写任何回应前):
Trying to do it like this as the last resort method (before writing any response):
context.Response.Filter = new DeflateStream(context.Response.Filter, CompressionMode.Compress);
context.Response.AppendHeader("Content-Encoding", "deflate");
日志记录表明,该code正确执行。
然而,Chrome的显示内容不COM pressed,一次。
Logging shows that this code is executed correctly. However, Chrome shows that content is not compressed, again.
UPD时使用IIS内置的COM pression,似乎工作,并请求跟踪显示DYNAMIC_COM preSSION_SUCCESS。但是,IE浏览器仍然显示的响应不是COM pressed。在当我使用本地主机名,要求从服务器本身的页面一样。
UPD when using IIS built-in compression, it seems to work and request tracing shows "DYNAMIC_COMPRESSION_SUCCESS". However, IE still shows that response is not compressed. The same when I'm requesting the page from the server itself using localhost name.
任何想法?
推荐答案
我还没有看到任何真正回答我的问题。最合理的猜测 - 在东西之间DECOM presses的响应结果。
如果你有一个更好的答案,随时分享 - 我将重新开放赏金
I still don't see any real answer to my question. The best guess - something in-between decompresses the response.
If you have a better answer, feel free to share - I will reopen bounty.
这篇关于COM pression不工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!