A cache, being a mechanism for efficient temporary storage of objects for the purpose of improving the overall performance of an application system, should not be necessary for the application to function correctly, it only improves the performance.
A cache could be scoped, for examples to a JVM, all JVMs on a node, all nodes in a cluster, etc. Operations that are scoped to a cache such as put or load would affect all JVMs in the cache. So the object loaded in 1 JVM would be equally available to all other JVMs in the cache.
Objects are identified in the cache by a key. A key can be any Java object that implements the equals and hashcode methods. If the object is to be distributed or persisted (if supported) it must implement serializable.
Each object in the cache will have aCacheEntry object associated with it. This object will encapsulate the metadata associated with the cached object. Mainly it represents the object statistics. "CacheStatistics" represents the read-only statistics of the cache, while "CacheAttributes" represents the user settable attributes of the cache.
|
|
|
|