Proxy caching
From Resin 3.0
Resin Professional's Web Server contains a high-performance proxy cache which lets well-designed applications improve performance and reduce database load.
In a heavily traffic site, even caching with a 15 second expires time can eliminate most of the backend database calls. To enable proxy caching in a page, just set the "Cache-Control: max-age=15" header.
response.addHeader("Cache-Control", "max-age=15");
Resin will automatically cache the page for 15 seconds.
Caching performance with mysql
A short example can show the value of the proxy caching in a database environment. The example has two trivial SQL queries, each returning 5-10 results. In other words, it's a light load. In a real example, the caching benefits would be more dramatic.
SELECT name, price FROM brooms SELECT name, points FROM houses
Without caching, Resin serves 1410 pages per second.
With caching, Resin serves 6330 pages per second.
Caching performance with gzip
Gzipped files can also be cached, and will also see a performance improvement. For a 64k page:
Without caching, Resin serves 350 pages per second
With caching, Resin serves 5670 pages per second
Using Proxy Caching with Load Balancing
Proxy Caching on the frontend server can be very effective with Load Balancing