Ask a questionAsk a question
 

QuestionCompression of bloated atom+xml

  • Tuesday, August 25, 2009 4:20 AMJif Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Is there any way to compress the DataServiceContext traffic to or from a server?

    There seems to be half a solution, in applicationHost.config setting the:
    <httpCompression directory="%SystemDrive%\inetpub\temp\IIS Temporary Compressed Files">
      <dynamicTypes>
         ...
         <add mimeType="*/*" enabled="true" />
      </dynamicTypes>
    </httpCompression>
    
    
    And on the Context:
    wr.Headers.Add("Accept-Encoding: gzip");
    
    
    Which is nice because it automatically compresses it when returned from the server.

    But then there's no way of getting the Client to decompress the result; it just falls flat on it's face.  Is there a way to:
    1. get the client to decompress the message;
    2. hook into the message before the client processes it;


    Thanks
    Geoff

    • Edited byJif Tuesday, August 25, 2009 4:29 AMadded question
    •  

All Replies