OSCache is a widely used, high performance J2EE caching solution.
The Problems Solved
OSCache solves fundamental problems for dynamic websites:
- Caching Dynamic Content - Dynamic content must often be executed in some form each
request, but sometimes that content doesn't change every request. Caching the whole page does
not help because sections of the page change every request.
- OSCache solves this problem by providing a means to cache sections of JSP pages.
- Caching Binary Content - Generated images and PDFs can be very costly in terms
of server load.
- OSCache solves this problem through a Servlet 2.3 CachingFilter which can cache any
URI (such as an entire page or a generated image/PDF)
- Error Tolerance - If one error occurs somewhere on your dynamic page, chances are the
whole page will be returned as an error, even if 95% of the page executed correctly.
- OSCache solves this problem by allowing you to serve the cached content in the event
of an error, and then reporting the error appropriately.
Brief Feature List
In addition to it's servlet-specific features, OSCache can be used as a generic caching
solution for any Java application. A few of its generic features include:
- Caching of Arbitrary Objects - You are not restricted to caching portions of JSP pages
or HTTP requests. Any Java object can be cached.
- Comprehensive API - The OSCache API gives you full programmatic control over all of
OSCache's features.
- Persistent Caching - The cache can optionally be disk-based, thereby allowing expensive-to-create
data to remain cached even across application restarts.
- Clustering - Support for clustering of cached data can be enabled with a single configuration
parameter. No code changes required.
- Expiry of Cache Entries - You have a huge amount of control over how cached objects expire,
including pluggable RefreshPolicies if the default functionality does not meet your requirements.
We encourage you to take a look at the full feature list to see what else
OSCache has to offer.
Other documentation: