Activating Compression (esp. Dynamic Compression) with IIS-Express

帅比萌擦擦* 提交于 2019-12-21 11:55:20

问题


Is it somehow possible to enable dynamic compression (for WCF-Services) on an IIS-Express?

It's a development environment issue so I cannot use the full version: but I need to figure out how it would behave with compression.


回答1:


Go to IIS Express installation folder (%programfiles%\IIS Express) and run the following command to enable dynamic compression.

appcmd set config -section:urlCompression /doDynamicCompression:true

Then add mime-types. Run following commands to add wildcard entries or take a look at http://www.iis.net/ConfigReference/system.webServer/httpCompression to add specific mime-types

 appcmd set config /section:httpCompression /staticTypes.[mimeType='*/*'].enabled:"true" /commit:apphost

  appcmd set config /section:httpCompression /dynamicTypes.[mimeType='*/*'].enabled:"true" /commit:apphost



回答2:


I found the configfile in Documents/IISExpress/config/applicationhost.config: here in the httpCompression-Section you can define the mime-types to use for dynamic compression.



来源:https://stackoverflow.com/questions/6572702/activating-compression-esp-dynamic-compression-with-iis-express

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!