|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.sakaiproject.search.index.impl.BaseIndexStorage
org.sakaiproject.search.index.impl.FSIndexStorage
public class FSIndexStorage
A local only filestore implementation. This is a simple IndexImplementation that performs all its indexing in a single, unoptimized segment on the local filesystem To set the location use location@org.sakaiproject.search.api.SearchService.LocalIndexStorage in sakai.properties Check that the bean name is correct in the spring components.xml file
| Field Summary | |
|---|---|
protected boolean |
recoverCorruptedIndex
|
protected String |
searchIndexDirectory
|
| Fields inherited from class org.sakaiproject.search.index.impl.BaseIndexStorage |
|---|
diagnostics |
| Constructor Summary | |
|---|---|
FSIndexStorage()
|
|
| Method Summary | |
|---|---|
boolean |
centralIndexExists()
A fast method that checks if the index exists in the cluster without opening or loading the index. |
void |
closeIndexReader(org.apache.lucene.index.IndexReader indexReader)
This will close the index reader and release any locks |
void |
closeIndexSearcher(org.apache.lucene.search.IndexSearcher indexSearcher)
|
void |
closeIndexWriter(org.apache.lucene.index.IndexWriter indexWrite)
this will close the index reader and release any locks |
protected boolean |
doIndexRecovery()
|
void |
doPostIndexUpdate()
perform all operations necessary after an update cycle |
void |
doPreIndexUpdate()
perform all operations before an update cycle |
org.apache.lucene.index.IndexReader |
getIndexReader()
get an Index Reader for the IndexStorage type |
protected org.apache.lucene.search.IndexSearcher |
getIndexSearcher()
|
org.apache.lucene.index.IndexWriter |
getIndexWriter(boolean create)
get an index writer, and create if asked to |
long |
getLastUpdate()
|
String |
getSearchIndexDirectory()
|
List |
getSegmentInfoList()
|
org.apache.lucene.store.Directory |
getSpellDirectory()
get the spell index directory |
boolean |
indexExists()
Does the index exist |
void |
init()
|
boolean |
isMultipleIndexers()
Returns true if its ok to allow multiple indexers to run at the same time The index storage may manage its own locks. |
boolean |
isRecoverCorruptedIndex()
|
void |
setLocation(String location)
|
void |
setRecoverCorruptedIndex(boolean recoverCorruptedIndex)
if set to true the IndexStorageWill automatically attempt to recover a corrupted index Not all IndexStorage implementations can do this, |
| Methods inherited from class org.sakaiproject.search.index.impl.BaseIndexStorage |
|---|
addReloadListener, disableDiagnostics, enableDiagnostics, fireIndexReload, forceNextReload, getAnalyzer, getAnalyzerFactory, getIndexSearcher, getLastLoad, getLastLoadTime, hasDiagnostics, removeReloadListener, setAnalyzerFactory |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected String searchIndexDirectory
protected boolean recoverCorruptedIndex
| Constructor Detail |
|---|
public FSIndexStorage()
| Method Detail |
|---|
public void init()
public void doPreIndexUpdate()
throws IOException
IndexStorage
IOException
public org.apache.lucene.index.IndexReader getIndexReader()
throws IOException
IndexStorage
IOException
public org.apache.lucene.index.IndexWriter getIndexWriter(boolean create)
throws IOException
IndexStorage
IOException
public void doPostIndexUpdate()
throws IOException
IndexStorage
IOExceptionpublic String getSearchIndexDirectory()
protected org.apache.lucene.search.IndexSearcher getIndexSearcher()
throws IOException
getIndexSearcher in class BaseIndexStorageIOException
protected boolean doIndexRecovery()
throws IOException
IOExceptionpublic boolean indexExists()
IndexStorage
public boolean isRecoverCorruptedIndex()
public void setRecoverCorruptedIndex(boolean recoverCorruptedIndex)
IndexStorage
recoverCorruptedIndex - The recoverCorruptedIndex to set.public void setLocation(String location)
public long getLastUpdate()
public List getSegmentInfoList()
public void closeIndexReader(org.apache.lucene.index.IndexReader indexReader)
throws IOException
IndexStorage
IOException
public void closeIndexWriter(org.apache.lucene.index.IndexWriter indexWrite)
throws IOException
IndexStorage
IOExceptionpublic boolean isMultipleIndexers()
IndexStorage
public void closeIndexSearcher(org.apache.lucene.search.IndexSearcher indexSearcher)
public boolean centralIndexExists()
IndexStorage
public org.apache.lucene.store.Directory getSpellDirectory()
IndexStorage
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||