Caching

The Expere Document Engine makes use of caching to improve performance for document related tasks. The cache can be configured to either use the third party ehcache library, or to use a basic in-memory HashMap.

The default configuration is to use the ehcache library, and this is the best all around choice. Using the ehcache library allows for much greater configuration, such as the ability to overflow cache items to disk and expire items from the cache. The HashMap cache is not recommended because it will grow unchecked in size, and may exhaust the available memory quickly. The cache scheme is configured in the bsi.properties file. The property com.bankerssystems.framework.cache.CacheFactory defines the cache implementation class to use. The class com.bankerssystems.framework.cache.ehcache.EHCacheFactory encapsulates ehcache, and the class com.bankerssystems.framework.cache.MapCacheFactory is the basic HashMap implementation.

The Expere Document Engine caches three things:

The basic HashMap cache has no configuration options and will simply grow unchecked in size. When using ehcache the cache configuration is defined in the ehcache.xml file in the Expere Document Engine EAR. The configuration of ehcache is documented at the ehcache project home at http://ehcache.sourceforge.net/. Notable features of ehcache are the ability to configure:

The default configuration of the caches assumes there will be a modest amount of system memory available. The cache is configured by default to store ten documents in memory, and then overflow to disk. If additional memory is available performance may be improved by allowing more documents to reside in memory.

Additional Caching Information