Hi,

Actually the event holds the value that is evicted as well. Please refer to
this listener example below:

    /** Eviction event listener. */
    private static class EvictListener implements IgnitePredicate<Event> {
        /** {@inheritDoc} */
        @Override public boolean apply(Event evt) {
            if (evt.type() == EVT_CACHE_ENTRY_EVICTED) {
                CacheEvent event = (CacheEvent)evt;

                System.out.println("Evicted key = " + event.key() + " ,
value=" + event.oldValue());
            }
            
            return true;
        }
    }


And please properly subscribe to the user list (this way we will not have to
manually approve your emails). All you need to do is send an email to
“[email protected]” and follow simple instructions in the
reply.

Regards,
Denis




--
View this message in context: 
http://apache-ignite-users.70518.x6.nabble.com/Is-there-a-way-to-get-the-value-that-was-evicted-from-the-cache-tp2032p2038.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Reply via email to