2010/03/12

Adding Http compression to ms crm

1.Download and install the HttpModule from http://capitalhead.com/articles/enable-http-compression-for-your-aspnet-applications.aspx. Simply follow this link and download the binary package.


2.Extract the package and copy the extracted files into the CRMWEB bin folder.
blowery.Web.HttpCompress.dll
blowery.Web.HttpCompress.dll.xml
ICSharpCode.SharpZipLib.dll
ICSharpCode.SharpZipLib.dll.xml

3.Modify your Web.config
1.Add to the configSections
<sectionGroup name="blowery.web"> <section name="httpCompress" type="blowery.Web.HttpCompress.SectionHandler, blowery.Web.HttpCompress"/></sectionGroup>


2.Add to the httpModules section inside system.web (if httpModules section does not exist, create it)

<httpModules><add name="CompressionModule" type="blowery.Web.HttpCompress.HttpModule, blowery.web.HttpCompress"/></httpModules>


3.Add to the configuration section

<blowery.web><httpCompress preferredAlgorithm="deflate" compressionLevel="high"> <excludedMimeTypes> <add type="image/jpeg"/> <add type="image/gif"/> </excludedMimeTypes> <excludedPaths></add path="AASA/_grid/cmds/dlg_exportcustomizations.aspx"</excludedPaths></httpCompress></blowery.web>

Please Note: When exporting or importing CRM customizations switch the compressin off.Set the compression setting in the webconfig file to "none"