WCF 4.5 supports GZIP without third party libraries or handwritten extensions. I got it working via TCP Binding, but cannot find a way to get it working via HTTP Binding. my wcf - Service is self hosted in a windows service.
Addon: i am not allowed to use IIS; i can't switch to any WCF replacement.
this works with gzip:
binding="customBinding" bindingConfiguration="tcpCompressionBinding" name="tcp"
and this is what i currently use for http:
binding="basicHttpBinding" bindingConfiguration="httpBinding" name="http"
The documentation does not really help me: http://msdn.microsoft.com/en-us/library/dd456789.aspx.
But, according to this it should work:
Beginning with WCF 4.5 the WCF binary encoder adds support for compression. The type of compression is configured with the CompressionFormat property. Both the client and the service must configure the CompressionFormat property. Compression will work for HTTP, HTTPS, and TCP protocols. If a client specifies to use compression but the service does not support it a protocol exception is thrown indicating a protocol mismatch. For more information, see Choosing a Message Encoder