java.lang.Object | |
↳ | org.apache.lucene.store.LockFactory |
Known Direct Subclasses |
Known Indirect Subclasses |
Base class for Locking implementation. Directory
uses
instances of this class to implement locking.
Note that there are some useful tools to verify that
your LockFactory is working correctly: VerifyingLockFactory
, LockStressTest
, LockVerifyServer
.
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
lockPrefix |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Attempt to clear (forcefully unlock and remove) the
specified lock.
| |||||||||||
Get the prefix in use for all locks created in this LockFactory.
| |||||||||||
Return a new Lock instance identified by lockName.
| |||||||||||
Set the prefix in use for all locks created in this
LockFactory.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Attempt to clear (forcefully unlock and remove) the specified lock. Only call this at a time when you are certain this lock is no longer in use.
lockName | name of the lock to be cleared. |
---|
IOException |
---|
Return a new Lock instance identified by lockName.
lockName | name of the lock to be created. |
---|
Set the prefix in use for all locks created in this LockFactory. This is normally called once, when a Directory gets this LockFactory instance. However, you can also call this (after this instance is assigned to a Directory) to override the prefix in use. This is helpful if you're running Lucene on machines that have different mount points for the same shared directory.