It's cached on my server using varnish http://varnish-cache.org, which uses LRU caching with ttls. A very cool open source web caching project. I use a configuration very similar to media wiki where I set long ttls and then have the backend send a PURGE http message followed by a GET to varnish when a file is updated to refresh the cache.