|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.solr.update.SolrCoreState
public abstract class SolrCoreState
The state in this class can be easily shared between SolrCores across SolrCore reloads.
Nested Class Summary | |
---|---|
static interface |
SolrCoreState.IndexWriterCloser
|
Field Summary | |
---|---|
protected boolean |
closed
|
static org.slf4j.Logger |
log
|
Constructor Summary | |
---|---|
SolrCoreState()
|
Method Summary | |
---|---|
abstract void |
cancelRecovery()
|
abstract void |
close(SolrCoreState.IndexWriterCloser closer)
|
abstract void |
closeIndexWriter(SolrCore core,
boolean rollback)
Expert method that closes the IndexWriter - you must call openIndexWriter(SolrCore)
in a finally block after calling this method. |
boolean |
decrefSolrCoreState(SolrCoreState.IndexWriterCloser closer)
|
abstract void |
doRecovery(CoreContainer cc,
CoreDescriptor cd)
|
abstract Lock |
getCommitLock()
|
abstract DirectoryFactory |
getDirectoryFactory()
|
abstract RefCounted<IndexWriter> |
getIndexWriter(SolrCore core)
Get the current IndexWriter. |
Object |
getUpdateLock()
|
void |
increfSolrCoreState()
|
abstract void |
newIndexWriter(SolrCore core,
boolean rollback)
Force the creation of a new IndexWriter using the settings from the given SolrCore. |
abstract void |
openIndexWriter(SolrCore core)
Expert method that opens the IndexWriter - you must call closeIndexWriter(SolrCore, boolean)
first, and then call this method in a finally block. |
abstract void |
rollbackIndexWriter(SolrCore core)
Rollback the current IndexWriter. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static org.slf4j.Logger log
protected boolean closed
Constructor Detail |
---|
public SolrCoreState()
Method Detail |
---|
public Object getUpdateLock()
public void increfSolrCoreState()
public boolean decrefSolrCoreState(SolrCoreState.IndexWriterCloser closer)
public abstract Lock getCommitLock()
public abstract void newIndexWriter(SolrCore core, boolean rollback) throws IOException
rollback
- close IndexWriter if false, else rollback
IOException
- If there is a low-level I/O error.public abstract void closeIndexWriter(SolrCore core, boolean rollback) throws IOException
openIndexWriter(SolrCore)
in a finally block after calling this method.
core
- that the IW belongs torollback
- true if IW should rollback rather than close
IOException
- If there is a low-level I/O error.public abstract void openIndexWriter(SolrCore core) throws IOException
closeIndexWriter(SolrCore, boolean)
first, and then call this method in a finally block.
core
- that the IW belongs to
IOException
- If there is a low-level I/O error.public abstract RefCounted<IndexWriter> getIndexWriter(SolrCore core) throws IOException
SolrCore
.
IOException
- If there is a low-level I/O error.public abstract void rollbackIndexWriter(SolrCore core) throws IOException
SolrCore
.
IOException
- If there is a low-level I/O error.public abstract DirectoryFactory getDirectoryFactory()
DirectoryFactory
that should be used.public abstract void doRecovery(CoreContainer cc, CoreDescriptor cd)
public abstract void cancelRecovery()
public abstract void close(SolrCoreState.IndexWriterCloser closer)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |