|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface MassIndexer
A MassIndexer is useful to rebuild the indexes from the data contained in the database. This process is expensive: all indexed entities and their indexedEmbedded properties are scrolled from database.
Method Summary | |
---|---|
MassIndexer |
batchSizeToLoadObjects(int batchSize)
Sets the batch size used to load the root entities. |
MassIndexer |
cacheMode(CacheMode cacheMode)
Sets the cache interaction mode for the data loading tasks. |
MassIndexer |
idFetchSize(int idFetchSize)
Specifies the fetch size to be used when loading primary keys if objects to be indexed. |
MassIndexer |
limitIndexedObjectsTo(long maximum)
EXPERIMENTAL method: will probably change Will stop indexing after having indexed a set amount of objects. |
MassIndexer |
optimizeAfterPurge(boolean optimize)
If index optimization should be run before starting, after the purgeAll. |
MassIndexer |
optimizeOnFinish(boolean optimize)
If index optimization has to be started at the end of the indexing process. |
MassIndexer |
progressMonitor(MassIndexerProgressMonitor monitor)
Override the default MassIndexerProgressMonitor . |
MassIndexer |
purgeAllOnStart(boolean purgeAll)
If all entities should be removed from the index before starting using purgeAll. |
Future<?> |
start()
Starts the indexing process in background (asynchronous). |
void |
startAndWait()
Starts the indexing process, and then block until it's finished. |
MassIndexer |
threadsForIndexWriter(int numberOfThreads)
Deprecated. |
MassIndexer |
threadsForSubsequentFetching(int numberOfThreads)
Sets the number of threads used to load the lazy collections related to the indexed entities. |
MassIndexer |
threadsToLoadObjects(int numberOfThreads)
Set the number of threads to be used to load the root entities. |
Method Detail |
---|
MassIndexer threadsToLoadObjects(int numberOfThreads)
numberOfThreads
-
MassIndexer batchSizeToLoadObjects(int batchSize)
batchSize
-
MassIndexer threadsForSubsequentFetching(int numberOfThreads)
numberOfThreads
-
@Deprecated MassIndexer threadsForIndexWriter(int numberOfThreads)
MassIndexer progressMonitor(MassIndexerProgressMonitor monitor)
MassIndexerProgressMonitor
.
monitor
- this instance will receive updates about the massindexing progress.
MassIndexer cacheMode(CacheMode cacheMode)
MassIndexer optimizeOnFinish(boolean optimize)
optimize
-
MassIndexer optimizeAfterPurge(boolean optimize)
optimize
-
MassIndexer purgeAllOnStart(boolean purgeAll)
purgeAll
-
MassIndexer limitIndexedObjectsTo(long maximum)
maximum
-
Future<?> start()
void startAndWait() throws InterruptedException
InterruptedException
- if the current thread is interrupted
while waiting.MassIndexer idFetchSize(int idFetchSize)
Integer.MIN_VALUE
otherwise it will attempt to preload everything in memory.
idFetchSize
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |