Overview of Hybrid Caching
A
full restartable
CacheManager stores
all of its cache data in server off-heap. A
hybrid restartable
CacheManager stores only
some (explained in
Configuring a Hybrid Cache section below) of its cache data in server off-heap. The off-heap tier in this scenario is
backed by a disk, meaning that the entries in the off-heap tier are a subset of the entries in the disk, and the disk provides crash-resilience to the cache data. This has the following advantages:
Cache size can exceed the available off-heap memory.
Predictable low latencies are guaranteed at very large scale.
Terracotta Ehcache provides the flexibility of configuring hybrid at the CacheManager level. Thus, we could have full as well as hybrid cache managers on the same Terracotta server.
Note: | Because of the random-access read/write pattern of hybrid, it is recommended to use hybrid with Solid State Drives (SSDs) only. |
In the subsequent sections, we'll refer to a hybrid restartable CacheManager simply as a hybrid CacheManager, because a non-restartable hybrid CacheManager does not exist.