Package org.apache.lucene.store
Class SingleInstanceLockFactory
java.lang.Object
org.apache.lucene.store.LockFactory
org.apache.lucene.store.SingleInstanceLockFactory
Implements
LockFactory for a single in-process instance, meaning all locking will take
place through this one instance. Only use this LockFactory when you are certain all
IndexWriters for a given index are running against a single shared in-process Directory instance.- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionobtainLock(Directory dir, String lockName) Return a new obtained Lock instance identified by lockName.
-
Constructor Details
-
SingleInstanceLockFactory
public SingleInstanceLockFactory()
-
-
Method Details
-
obtainLock
Description copied from class:LockFactoryReturn a new obtained Lock instance identified by lockName.- Specified by:
obtainLockin classLockFactory- Parameters:
lockName- name of the lock to be created.- Throws:
IOException- if any i/o error occurs attempting to gain the lock
-