Taejoon Kim
Taejoon Kim

Reputation: 1

How to get an evicted item in Apache Ignite

Is there a way to get an evicted item in Apache Ignite?

I set LRU eviction policy.

I assume that when I put a new key and a value, if the cache space is full, then one item is evicted by LRU eviction policy, and then the new key and value cached.

If it is correct, I wanna know which key and value are evicted.

Is there a way to know that?

Upvotes: 0

Views: 177

Answers (1)

Max
Max

Reputation: 379

You can listen to EVT_CACHE_ENTRY_EVICTED. There is a test which shows how to do it properly.

Upvotes: 2

Related Questions