On 19 Oct 2009, at 08:16, Emmanuel Bernard wrote: > On the Lucene side, it seems to me that manually asking for a lock > clear is cleaner / safer than this automagic approach.
Yeah, I agree with Emmanuel - a more explicit form would work better IMO. Perhaps what you could do is something like this: 1) Create an entry, name "sharedlock", value "address of current lock owner". 2) Any time a node needs a lock, adds its addess to the "sharedlock" entry only if it doesn't exist (putIfAbsent) 3) If the entry exists , check if the address is still in the cluster (check using CacheManager.getMembers()). If the address doesn't exist (stale lock) remove and overwrite (using replace() to prevent concurrent overwrites) WDYT? - Manik -- Manik Surtani ma...@jboss.org Lead, Infinispan Lead, JBoss Cache http://www.infinispan.org http://www.jbosscache.org _______________________________________________ hibernate-dev mailing list hibernate-dev@lists.jboss.org https://lists.jboss.org/mailman/listinfo/hibernate-dev