I am receiving xml files on my server using the HTTP PUT request. Is it compressed during the transfer if my Apache is configured with mod_deflate? How can I verify that it is compress? If not, how can I force the compression?
Thanks!
I am receiving xml files on my server using the HTTP PUT request. Is it compressed during the transfer if my Apache is configured with mod_deflate? How can I verify that it is compress? If not, how can I force the compression?
Thanks!
The
mod_deflate
is used when apache sends data, not when receiving.The thing is that the browser sends data to the web server before having any knowledge of what it supports, thus, it cannot compress data, not knowing if the server will be able to handle it.
If you're really in need a lower bandwidth usage, you should have the xml files compressed before sending them, and uncompressed them in your application.
As per my previous answer:
A browser requests content to be compressed by setting Accept-Encoding header as per here
This will return compressed data to the browser. However, to PUT data to the server compressed, you must compress the whole request, inclusive of header. It's documented in mod_deflate:
And an article describing it is here: