Zlibcompression FILTER
As an example, we use the DATASNAP filter that has been supplied with D2010. Can be used to compress data flow on both the client and the server side. It says here.
The Zlibcompression filter can be found in the Dbxcompressionfilter unit.
Both the Tdstcpserver and Tdshttpservice components have a filters property of type Ttransportfilterscollection. Click Filters
property to edit the filter list. In this dialog, we can add a new ttransportfilteritem, and then in the object
Set Filterid and some properties in Inspector. In the drop-down box, you can find the Zlibcompression filter provided by Delphi2010.
Note that in addition to setting the server-side Tdstcpservertransport Component filters property, you also need to specify a corresponding filter on the client
(Compression request decompression answer). At this point, we need to reference the Dbxcompressionfilter unit to Clientform. It will automatically register a
Ttransportcompressionfilter and communicates with the server.
If you do not add a Dbxcompressionfilter cell reference to the client, the exception message will be thrown after running the client:
Use of DATASNAP compression filters