Any way of compressing XML when downloading from server to client?
I have a major problem, as I deal with very large + long tables.
The resulting XML can be as big as 4MB. So, very long to download.
I wonder if anything exists giving the chance to compress/decompress XML prior to transmission / prior to usage.
Any hint would be highly appreciated.
since I use XML data representation model, does virtual mode affect in any way the need to transmit the FULL xml file from the server to te client??
From the tests I've done, it looks like it doesn't: it actually doesn't makes any difference wether I set virtual mode ON/OFF in terms of tranmission times....
Kurt: if that's all the data I need to send to the client (coming out from very complex DB queries) what can I do?
Thanks for your help
What percentage of your XML is data, whitespace and markup?
Randall Severy might have been referring to /datagrid.13524/when-will-ajax-paging-be.html
So, when the user scrolls the grid, the rows that need to be displayed are fetched from the server using an AJAX call and then displayed.
The user doesn't need to download the entire 4 MB.
Some changes will be required in your server side code to respond with JSON data (or respond with XML data - change Alex's code given in the URL to accept XML) to the AJAX call.
If the amount of data is expected to increase in future, it might be a good idea to implement this instead of compression.
Otherwise, there might be a point when despite compression, the data size is too huge.
If you don't want to implement the above and just want compression, mod_gzip on apache might be the best option, as suggested by J.D. Pace.
Plus , as a bonus, it will compress all pages it serves (it detects if the browser supports compression) and not just the XML data :)
If you would like to see how much it will compress, just gzip your data and check the size.
It will compress by approximately the same amount and you should be able to decide if it is worth the effort.
If you are using PHP, there's another alternative to mod_gzip.
Check out http://au.php.net/ob_gzhandler
If you are using a language other than PHP, it might have an equivalent statement.
I really have to thank you all for your support, highly appreciated, really.
I have now an important development thread to investigate, and will come back to you with the results.
1 - Amount od XML-specific stuff VS. real payload: ENORMOUS. More than 80% can be tags...
2 - My environment is a classic LAMP
This topic is archived.
Back to support forum
Version 2Looking for AW 2.6 ?
The old site is here.