public class SolrIndexWriter
extends org.apache.lucene.index.IndexWriter
| Modifier and Type | Class and Description |
|---|---|
(package private) class |
SolrIndexWriter.TimeLoggingPrintStream |
| Modifier and Type | Field and Description |
|---|---|
private java.io.PrintStream |
infoStream |
private boolean |
isClosed
use DocumentBuilder now...
|
static java.lang.String |
LOCK_TYPE_NATIVE |
static java.lang.String |
LOCK_TYPE_NONE |
static java.lang.String |
LOCK_TYPE_SIMPLE |
static java.lang.String |
LOCK_TYPE_SINGLE |
private static org.slf4j.Logger |
log |
(package private) java.lang.String |
name |
| Constructor and Description |
|---|
SolrIndexWriter(java.lang.String name,
java.lang.String path,
DirectoryFactory dirFactory,
boolean create,
IndexSchema schema,
SolrIndexConfig config,
org.apache.lucene.index.IndexDeletionPolicy delPolicy) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
protected void |
finalize() |
static org.apache.lucene.store.Directory |
getDirectory(java.lang.String path,
DirectoryFactory directoryFactory,
SolrIndexConfig config) |
void |
rollback() |
addDocument, addDocument, addDocuments, addDocuments, addIndexes, addIndexes, addIndexesNoOptimize, close, commit, commit, deleteAll, deleteDocuments, deleteDocuments, deleteDocuments, deleteDocuments, deleteUnusedFiles, doAfterFlush, doBeforeFlush, ensureOpen, ensureOpen, expungeDeletes, expungeDeletes, flush, flush, forceMerge, forceMerge, forceMergeDeletes, forceMergeDeletes, getAnalyzer, getConfig, getDefaultInfoStream, getDefaultWriteLockTimeout, getDirectory, getInfoStream, getMaxBufferedDeleteTerms, getMaxBufferedDocs, getMaxFieldLength, getMaxMergeDocs, getMergedSegmentWarmer, getMergeFactor, getMergePolicy, getMergeScheduler, getMergingSegments, getNextMerge, getPayloadProcessorProvider, getRAMBufferSizeMB, getReader, getReader, getReaderTermsIndexDivisor, getSimilarity, getTermIndexInterval, getUseCompoundFile, getWriteLockTimeout, hasDeletions, isLocked, maxDoc, maybeMerge, merge, message, numDeletedDocs, numDocs, numRamDocs, optimize, optimize, optimize, prepareCommit, prepareCommit, ramSizeInBytes, segString, segString, segString, setDefaultInfoStream, setDefaultWriteLockTimeout, setInfoStream, setMaxBufferedDeleteTerms, setMaxBufferedDocs, setMaxFieldLength, setMaxMergeDocs, setMergedSegmentWarmer, setMergeFactor, setMergePolicy, setMergeScheduler, setPayloadProcessorProvider, setRAMBufferSizeMB, setReaderTermsIndexDivisor, setSimilarity, setTermIndexInterval, setUseCompoundFile, setWriteLockTimeout, unlock, updateDocument, updateDocument, updateDocuments, updateDocuments, verbose, waitForMergesprivate static org.slf4j.Logger log
public static final java.lang.String LOCK_TYPE_SIMPLE
public static final java.lang.String LOCK_TYPE_NATIVE
public static final java.lang.String LOCK_TYPE_SINGLE
public static final java.lang.String LOCK_TYPE_NONE
java.lang.String name
private java.io.PrintStream infoStream
private volatile boolean isClosed
public SolrIndexWriter(java.lang.String name,
java.lang.String path,
DirectoryFactory dirFactory,
boolean create,
IndexSchema schema,
SolrIndexConfig config,
org.apache.lucene.index.IndexDeletionPolicy delPolicy)
throws java.io.IOException
java.io.IOExceptionpublic static org.apache.lucene.store.Directory getDirectory(java.lang.String path,
DirectoryFactory directoryFactory,
SolrIndexConfig config)
throws java.io.IOException
java.io.IOExceptionpublic void close()
throws java.io.IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseableclose in class org.apache.lucene.index.IndexWriterjava.io.IOExceptionpublic void rollback()
throws java.io.IOException
rollback in interface org.apache.lucene.util.TwoPhaseCommitrollback in class org.apache.lucene.index.IndexWriterjava.io.IOExceptionprotected void finalize()
throws java.lang.Throwable
finalize in class java.lang.Objectjava.lang.Throwable