@ThreadSafe public class ClusteredLockingService extends AbstractLockingService<Lock>
logger| Constructor and Description |
|---|
ClusteredLockingService(org.jgroups.Channel channel,
long lockTimeoutMillis)
Creates a new service instance using the supplied JGroups channel.
|
| Modifier and Type | Method and Description |
|---|---|
protected Lock |
createLock(String name) |
protected void |
doShutdown() |
protected boolean |
releaseLock(Lock lock) |
protected void |
validateLock(Lock lock) |
public ClusteredLockingService(org.jgroups.Channel channel,
long lockTimeoutMillis)
Note that the channel is expected to have been initialized and the CENTRAL_LOCK protocol added.
channel - a Channel instance; may not be nulllockTimeoutMillis - the number of millis to wait before timing out when attempting to obtain a lockprotected Lock createLock(String name)
createLock in class AbstractLockingService<Lock>protected void validateLock(Lock lock)
validateLock in class AbstractLockingService<Lock>protected boolean releaseLock(Lock lock)
releaseLock in class AbstractLockingService<Lock>protected void doShutdown()
doShutdown in class AbstractLockingService<Lock>Copyright © 2008–2016 JBoss, a division of Red Hat. All rights reserved.