Welcome to WebmasterWorld Guest from 54.146.239.96

Forum Moderators: Ocean10000 & incrediBILL & phranque

Message Too Old, No Replies

Caching the result of compression

How to avoid recompressing same unchanging data for lower latency&CPU load

     

true_INFP

2:58 pm on Mar 31, 2011 (gmt 0)

5+ Year Member



Hello,

If you have static pages or unchanging files on your server that are compressible, it is a good idea to compress them to save bandwidth.

However, when you enable mod_gzip or mod_deflate, will the result of the compression be cached in RAM so the data won't be redundantly re-compressed each time it is requested?

If not, is there a way to achieve that? Once a file or static page is compressed, it is stored in a RAM buffer and if the time stamp of the original file does not change, the cached compressed version is served directly?

Thanks.

lammert

2:53 am on Apr 1, 2011 (gmt 0)

WebmasterWorld Senior Member lammert is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month



You can use the content negotiation option of Apache to do this. There is a somewhat dated discussion about this at [webmasterworld.com...] which covers both the techniques and performance part. Please remember that the thread is some years old and both hardware and software techniques may have improved over time.

true_INFP

8:20 am on Apr 1, 2011 (gmt 0)

5+ Year Member



Thank you very much--exactly what I was looking for! :)