cb372 / scalacache

Simple caching in Scala
https://cb372.github.io/scalacache/
Other
772 stars 120 forks source link

Refresh after write support #568

Open veysiertekin opened 3 years ago

veysiertekin commented 3 years ago

Current scalacache default implementation allows us to cache values for a desired duration (TTL). In some cases, we may need to refresh value in parallel without expiring it, just like Guava/Caffeine's refreshAfterWrite behaviour.

Maybe this involve adding another mode kind of behaviour for caching strategies. Hope sometime we will see this feature in scalacache!

jeet23 commented 2 years ago

Plus 1 for this feature request.

It would be great to have the refreshAfterWrite feature added in scalacache (like Caffeine, Guava etc), so that we can use the CacheLoader to refresh the cache values without ever expiring it.

niij commented 2 years ago

+1