[jboss-dev-forums] [Design of JBossCache] - Re: state transfer failure handling

vblagojevic@jboss.com do-not-reply at jboss.com
Thu Sep 14 11:48:02 EDT 2006


So lets bundle reading/writing transient and associated state as one atomic step since they deal exclusively with in-memory tree and reading/writing persistent state as another atomic step. Lets call them step 1 and step 2.


Is the algorithm you have in mind something along the lines of:

Reading:

obtain lock on transient node at integration point
do step 1
if any part of step 1 fails
	clear transient tree at integration point and clear pojo map
release lock on transient node at integration point

obtain lock on CacheLoaderManager at node integration point
if (step 1 failed and it is a specific case Brian mentioned) or (step 1 success)
	do step2
if step 2 fails clear cacheloader at node integration point
release lock on CacheLoaderManager at node integration point 


Writing:

obtain lock on transient node 
do step 1
release lock on transient node 

obtain lock on CacheLoaderManager at node generation point
if (step 1 failed and it is a specific case Brian mentioned) or (step 1 success)
	do step2
release lock on CacheLoaderManager at node generation point

Any corrections or suggestions?

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3971597#3971597

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3971597



More information about the jboss-dev-forums mailing list