Class OptimizeModeListener
- java.lang.Object
-
- de.hybris.platform.solrfacetsearch.indexer.listeners.OptimizeModeListener
-
- All Implemented Interfaces:
IndexerListener
public class OptimizeModeListener extends java.lang.Object implements IndexerListener
Listener that applies the optimize mode.
-
-
Field Summary
Fields Modifier and Type Field Description protected static OptimizeModeDEFAULT_OPTIMIZE_MODEprotected static java.lang.StringOPTIMIZE_MODE_HINT
-
Constructor Summary
Constructors Constructor Description OptimizeModeListener()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidafterIndex(IndexerContext context)Handles a notification that the indexing for a particularIndexerContexthas just been completed.voidafterIndexError(IndexerContext context)Handles a notification that the indexing for a particularIndexerContextfailed.voidbeforeIndex(IndexerContext context)Handles a notification that the indexing for a particularIndexerContextis about to begin.SolrSearchProviderFactorygetSolrSearchProviderFactory()protected voidoptimize(FacetSearchConfig facetSearchConfig, IndexedType indexedType, Index index)protected OptimizeModeresolveOptimizeMode(FacetSearchConfig facetSearchConfig, java.util.Map<java.lang.String,java.lang.String> indexerHints)voidsetSolrSearchProviderFactory(SolrSearchProviderFactory solrSearchProviderFactory)
-
-
-
Field Detail
-
DEFAULT_OPTIMIZE_MODE
protected static final OptimizeMode DEFAULT_OPTIMIZE_MODE
-
OPTIMIZE_MODE_HINT
protected static final java.lang.String OPTIMIZE_MODE_HINT
- See Also:
- Constant Field Values
-
-
Method Detail
-
beforeIndex
public void beforeIndex(IndexerContext context) throws IndexerException
Description copied from interface:IndexerListenerHandles a notification that the indexing for a particularIndexerContextis about to begin.- Specified by:
beforeIndexin interfaceIndexerListener- Parameters:
context- - theIndexerContext- Throws:
IndexerException- if an error occurs
-
afterIndex
public void afterIndex(IndexerContext context) throws IndexerException
Description copied from interface:IndexerListenerHandles a notification that the indexing for a particularIndexerContexthas just been completed.- Specified by:
afterIndexin interfaceIndexerListener- Parameters:
context- - theIndexerContext- Throws:
IndexerException- if an error occurs
-
afterIndexError
public void afterIndexError(IndexerContext context) throws IndexerException
Description copied from interface:IndexerListenerHandles a notification that the indexing for a particularIndexerContextfailed.- Specified by:
afterIndexErrorin interfaceIndexerListener- Parameters:
context- - theIndexerContext- Throws:
IndexerException- if an error occurs
-
resolveOptimizeMode
protected OptimizeMode resolveOptimizeMode(FacetSearchConfig facetSearchConfig, java.util.Map<java.lang.String,java.lang.String> indexerHints)
-
optimize
protected void optimize(FacetSearchConfig facetSearchConfig, IndexedType indexedType, Index index) throws IndexerException
- Throws:
IndexerException
-
setSolrSearchProviderFactory
public void setSolrSearchProviderFactory(SolrSearchProviderFactory solrSearchProviderFactory)
-
getSolrSearchProviderFactory
public SolrSearchProviderFactory getSolrSearchProviderFactory()
-
-