Please make sure that "cache.size(CachePeek.ALL)" returns 0 when you
consider that the cache is empty.
I have a feeling that your logic has not removed something. Use
"cache.iterator()" to find the entries that are not removed.
BTW, there is no need to call "cache.remove()" and "cache.clear()" right
after that. Just use one method.
--
Denis
On 11/24/2015 10:34 AM, wychoi wrote:
hi
ongoing stop/start of some server node after the whole cache clearing
All caches have been removed. (cache -scan -c=CACHE_NAME) : confirm empty
But remain few cache in cacheMetricsMxBean of visualvm
Then i see that some entities got resurrected
this is code snipet
public boolean remove(String cacheName, Long key, Integer part) throws
IgniteException {
Ignite ignite = Ignition.ignite();
AffinityKey affKey = new AffinityKey(key, part);
IgniteCache<AffinityKey, XObject> cache =
ignite.cache(cacheName);
result = cache.remove(affKey);
cache.clear(affKey);
return result;
}
--
View this message in context:
http://apache-ignite-users.70518.x6.nabble.com/remove-cache-on-high-speed-tp2039p2044.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.