public final class VerifyingLockFactory extends LockFactory
LockFactorythat wraps another
LockFactoryand verifies that each lock obtain/release is "correct" (never results in two processes holding the lock at the same time). It does this by contacting an external server (
LockVerifyServer) to assert that at most one process holds the lock at a time. To use this, you should also run
LockVerifyServeron the host and port matching what you pass to the constructor.
|Constructor and Description|
|Modifier and Type||Method and Description|
Return a new obtained Lock instance identified by lockName.
public Lock obtainLock(Directory dir, String lockName) throws IOException
Copyright © 2000-2020 Apache Software Foundation. All Rights Reserved.