thanks for spotting this.
This is a bug, indeed.
I've created http://jira.jboss.com/jira/browse/JBCACHE-1384
It is good that override is false at that point (that means that we do not want to *replace* the existing value). The problem is that overriding logic is broken, the old values override the new ones.
Here is my fix:
if(!override && oldNode != NULL_NODE_IN_ROW && attrs != null)
Map newOne = new HashMap(oldNode);
if(attrs != null) newOne.putAll(attrs);
attrs = newOne;
Is there an easy way to save all in-memory state to Database. I need to update database state, since it may be corrupt, prior to updating my running instances with a patched version of JDBCCacheLoader with the fix you suggested?
Any help will be appreciated.
an idea would be to have a small program that
a) starts a new cluster instance which would fetch all in memory state
b) this instance uses passivation
c) call cache.evict after state retrieval finished
I was already working on it, although I didn't thought on passivation, rather in a cache.put for every node. I'll try cache.evict, as it seems rather easier.
It seems that if I evict FQN.ROOT, only evicts nodes at primary level, and not its descendants.