[jboss-user] [JBoss Cache: Core Edition] - Manual node locking?

tomstrummer do-not-reply at jboss.com
Wed Jun 17 12:23:07 EDT 2009

So I suspect this is somewhat of an odd request...  

I'm trying to implement OpenFire's clustering plugin using JBossCache.  I can implement their cache interface pretty easily, save for one method - getLock.

So OpenFire wants to manually acquire and release locks on cached objects.  Beyond that, OpenFire _is_ the server- it's not a J2EE app- so there's no TransactionManager to be found.  

So is there any way I can directly access JBossCache's locking APIs? (even if it requires accessing non-public implementation classes)

I'm trying to think of a way I could "manually" synchronize on an object via the cache - i.e. perform a "put," and if the operation does not return a "previous value" assume I have the lock.  But I'm not sure that's entirely safe either.  Any ideas on how I could accomplish such a thing?


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

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

More information about the jboss-user mailing list