Is it possible to implement a cache refresh behaviour using Ehcache 3.x?

149 views Asked by At

Can EhCache 3.x caches be configured to implement a refresh operation (see https://github.com/google/guava/wiki/CachesExplained#refresh for an example as implemented using Guava) - i.e. if the entry is expired, return the expired entry until the refreshed entry has been retrieved? This looks like it might have been possible under the 2.x versions using a decorator like http://www.ehcache.org/apidocs/2.10.3/net/sf/ehcache/constructs/refreshahead/RefreshAheadCache.html (although even this doesn't really match my use case, it looks like it always performs the refresh rather than only on expired entries) but I can't find any equivalent for the more recent releases.

Is this something that should be handled at a higher level? In the context of a Spring Boot application, is there another mechanism by which this could be done while using EhCache as the backing implementation?

0

There are 0 answers