MemoryConstrainedCacheManager

Simple memory-only based {@link CacheManager CacheManager} implementation usable in production environments. It will not cause memory leaks as it produces {@link Cache Cache}s backed by {@link SoftHashMap SoftHashMap}s which auto-size themselves based on the runtime environment's memory limitations and garbage collection behavior. <p/> While the {@code Cache} instances created are thread-safe, they do not offer any enterprise-level features such as cache coherency, optimistic locking, failover or other similar features. For more enterprise features, consider using a different {@code CacheManager} implementation backed by an enterprise-grade caching product (Hazelcast, EhCache, TerraCotta, Coherence, GigaSpaces, etc, etc).

@since 1.0

class MemoryConstrainedCacheManager : AbstractCacheManager!(K, V)(
K
V
) {}

Members

Functions

createCache
Cache!(K, V) createCache(string name)

Returns a new {@link MapCache MapCache} instance backed by a {@link SoftHashMap}.

Meta