Package org.hibernate.search.jmx
Class IndexingProgressMonitor
java.lang.Object
org.hibernate.search.jmx.IndexingProgressMonitor
- All Implemented Interfaces:
MassIndexerProgressMonitor,IndexingProgressMonitorMBean
public class IndexingProgressMonitor
extends Object
implements IndexingProgressMonitorMBean, MassIndexerProgressMonitor
A JMX based mass indexer progress monitor. This monitor will allow you to follow mass indexing progress via JMX.
-
Field Summary
Fields inherited from interface org.hibernate.search.jmx.IndexingProgressMonitorMBean
INDEXING_PROGRESS_MONITOR_MBEAN_OBJECT_NAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal voidaddToTotalCount(long count) The total count of entities to be indexed is added here; It could be called more than once, the implementation should add them up.final voiddocumentsAdded(long increment) The number of documents sent to the backend; This is invoked several times during the indexing process.final voiddocumentsBuilt(int number) The number of Documents built; This is invoked several times and concurrently during the indexing process.final voidentitiesLoaded(int size) The number of entities loaded from database; This is invoked several times and concurrently during the indexing process.final longfinal longfinal longfinal voidInvoked when the indexing is completed.
-
Constructor Details
-
IndexingProgressMonitor
public IndexingProgressMonitor()
-
-
Method Details
-
documentsAdded
public final void documentsAdded(long increment) Description copied from interface:MassIndexerProgressMonitorThe number of documents sent to the backend; This is invoked several times during the indexing process.- Specified by:
documentsAddedin interfaceMassIndexerProgressMonitor- Parameters:
increment- number of documents sent to backend
-
documentsBuilt
public final void documentsBuilt(int number) Description copied from interface:MassIndexerProgressMonitorThe number of Documents built; This is invoked several times and concurrently during the indexing process.- Specified by:
documentsBuiltin interfaceMassIndexerProgressMonitor- Parameters:
number- number ofDocuments built
-
entitiesLoaded
public final void entitiesLoaded(int size) Description copied from interface:MassIndexerProgressMonitorThe number of entities loaded from database; This is invoked several times and concurrently during the indexing process.- Specified by:
entitiesLoadedin interfaceMassIndexerProgressMonitor- Parameters:
size- number of entities loaded from database
-
addToTotalCount
public final void addToTotalCount(long count) Description copied from interface:MassIndexerProgressMonitorThe total count of entities to be indexed is added here; It could be called more than once, the implementation should add them up. This is invoked several times and concurrently during the indexing process.- Specified by:
addToTotalCountin interfaceMassIndexerProgressMonitor- Parameters:
count- number of newly indexed entities which has to be added to total count
-
indexingCompleted
public final void indexingCompleted()Description copied from interface:MassIndexerProgressMonitorInvoked when the indexing is completed.- Specified by:
indexingCompletedin interfaceMassIndexerProgressMonitor
-
getLoadedEntitiesCount
public final long getLoadedEntitiesCount()- Specified by:
getLoadedEntitiesCountin interfaceIndexingProgressMonitorMBean- Returns:
- the number of entities loaded so far
-
getDocumentsAddedCount
public final long getDocumentsAddedCount()- Specified by:
getDocumentsAddedCountin interfaceIndexingProgressMonitorMBean- Returns:
- the number of Lucene
Documents added so far
-
getNumberOfEntitiesToIndex
public final long getNumberOfEntitiesToIndex()- Specified by:
getNumberOfEntitiesToIndexin interfaceIndexingProgressMonitorMBean- Returns:
- the total number of entities which need indexing
-