org.apache.lucene.index
Class ExecutorMergeScheduler
java.lang.Object
org.apache.lucene.index.MergeScheduler
org.apache.lucene.index.ExecutorMergeScheduler
public class ExecutorMergeScheduler
- extends MergeScheduler
The executor merge scheduler is similar to Lucene ConcurrentMergeScheduler
but instead of spawning threads it uses Compass ExecutorManager in order
to execute the merges.
Since the executor manager is a thread pool, there is no need to have the running threads continue to
ask the index writer for more merges. Instead, it simple reexecute another possible merge with the executor manager.
- Author:
- kimchy
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
anyExceptions
static boolean anyExceptions
ExecutorMergeScheduler
public ExecutorMergeScheduler(ExecutorManager executorManager,
TransactionContext transactionContext)
getMaxConcurrentMerges
public int getMaxConcurrentMerges()
setMaxConcurrentMerges
public void setMaxConcurrentMerges(int maxConcurrentMerges)
close
public void close()
- Specified by:
close in class MergeScheduler
merge
public void merge(IndexWriter writer)
throws CorruptIndexException,
IOException
- Specified by:
merge in class MergeScheduler
- Throws:
CorruptIndexException
IOException
setSuppressExceptions
void setSuppressExceptions()
- Used for testing
clearSuppressExceptions
void clearSuppressExceptions()
- Used for testing
Copyright (c) 2004-2008 The Compass Project.