This is called when the context is created.
ServletContext context = sce.getServletContext();
// see if a cache manager is already created and set in the context
CacheManager cm = (CacheManager)context.getAttribute(CacheManager.CACHE_MANAGER_ATTR_NAME);
// create a new cachemanager if one is not present and use it
// to create a new cache
if (cm == null)
cm = new CacheManager();
Cache cache = null;
try {
cache = cm.createCache();
} catch (Exception ex) {}
// set the cache as a context attribute
if (cache != null)
context.setAttribute(Constants.JSPTAG_CACHE_KEY, cache);