Questions tagged [google-guava-cache]
97 questions
0
votes
1 answer
How to get from the loadingcache without triggering a load
I'm using java 8 and guava 14.0
I set up a LoadingCache and a CacheLoader with a load(). The code works every time I get from the cache the load () is called
There are times where I want to check if data is in the cache without calling the load(). …

Barry F
- 71
- 1
- 4
0
votes
1 answer
Preventing entries from getting evicted from Guava Cache
I was going through Guava Cache examples and wondered is there a way to prevent some entries from getting evicted from the cache on some condition.
Like, if an entry is being used by an application, it's unlikely you would like it to get…

Akshat
- 720
- 9
- 24
0
votes
1 answer
Difference between different type of caches and their significance
What is the difference between the Ehcache and Guava Cache? In which scenarios would I use which type of caching?

Pavan kumar
- 3
- 3
-1
votes
1 answer
Guava Cache - InvalidCacheLoadException on refresh
I have created a cache using CacheBuilder.
I have used ExpireAfterWrite and RefreshAfterWrite. I have overrided cacheloader load and reload function. Practically in reload I am calling load by creating ListenableFutureTask and submitting it to…

user3671657
- 37
- 1
- 8
-1
votes
2 answers
Facing issue with Guava Cache
I'm using Google Guava Cache + Spring cache abstraction for caching purpose.
I'm trying to make use of Guava's Loading Cache interface for the same.
I know Spring provides support for Guava Cache, but I was wondering whether I can make use of…

Sandy
- 459
- 2
- 6
- 19
-1
votes
1 answer
How to pass two pass one more parameter other than key in google guava cache
I have create a cache using google guava cache
here is my implementation of it
private final LoadingCache channelServiceCache = CacheBuilder.newBuilder().maximumSize(50)
.refreshAfterWrite(4, TimeUnit.HOURS).build(new…

Boola
- 358
- 3
- 14
-2
votes
1 answer
Which method is executed to expire Guava cache using expireAfterAccess?
I am using Guava cache manager and setting expireAfterAccess value.
I want to know which method is invoked to expire entries from the cache?

saurabh wani
- 1
- 1