Gemfire offers Time To Live for an element?

255 views Asked by At

Like in EHCache, we can set maximum time for an element to stay in the cache, after the timeout it will automatically get evicted/removed.

Since I am newbie to Gemfire, can any expert share whether this functionality is available in Gemfire?

2

There are 2 answers

0
dturanski On

Gemfire does support TTL at the Region and entry level. Have a look at the docs

0
John Blum On

Keep in mind that data (Region entry) "eviction" is not the same thing as "expiration".

TTI (idle-timeout) and TTL (time-to-live) refer to "expiration" settings where as LRU (and other algorithms like LFU) are "eviction" settings and can be configured with different behaviors (a.k.a. "actions") depending on the application functional requirements and use cases.

See how GemFire Eviction works as well as how Expiration works, and how the 2 settings are configured (Eviction, Expiration), respectively.