Saturday, August 1, 2009

Increase performance of applications with servlet caching

WebSphere Application Server (Version 5,6,6.1) provides the servlet caching option to increase the performance of applications. If servlet caching is enabled, the servlet output will be held in RAM of the physical application server. As an result clients can be served faster. In my tests i noticed a performance increase about 50 percent.
So how to enable servlet caching?
1. In administrative console go to
Application servers > "Server name" > Container services > Dynamic cache service
and set "Enable service at server startup" to true.

2. Go to
Application servers > "Server name" > Web container and enable servlet caching for this application server
3. Restart the application server

More RAM-Space is needed to cache the output.
Servlet output will be cached in RAM during first invocation of JSP/Servlet.