Class LogFailureHandler
- java.lang.Object
-
- org.hibernate.search.engine.reporting.impl.LogFailureHandler
-
- All Implemented Interfaces:
FailureHandler
public class LogFailureHandler extends Object implements FailureHandler
- Since:
- 3.2
- Author:
- Amin Mohammed-Coleman, Sanne Grinovero
-
-
Constructor Summary
Constructors Constructor Description LogFailureHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longfailureFloodingThreshold()When this handler is used for handling mass indexing failures - returns the number of failures during one mass indexing beyond which the failure handler will no longer be notified.voidhandle(EntityIndexingFailureContext context)Handle the failure of entity indexing.voidhandle(FailureContext context)Handle a generic failure.
-
-
-
Field Detail
-
NAME
public static final String NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
handle
public void handle(FailureContext context)
Description copied from interface:FailureHandlerHandle a generic failure.This method is expected to report the failure somewhere (logs, ...), then return as quickly as possible. Heavy error processing (sending emails, ...), if any, should be done asynchronously.
Any error or exception thrown by this method will be caught by Hibernate Search and logged.
- Specified by:
handlein interfaceFailureHandler- Parameters:
context- Contextual information about the failure (throwable, operation, ...)
-
handle
public void handle(EntityIndexingFailureContext context)
Description copied from interface:FailureHandlerHandle the failure of entity indexing.This method is expected to report the failure somewhere (logs, ...), then return as quickly as possible. Heavy error processing (sending emails, ...), if any, should be done asynchronously.
Any error or exception thrown by this method will be caught by Hibernate Search and logged.
- Specified by:
handlein interfaceFailureHandler- Parameters:
context- Contextual information about the failure (throwable, operation, ...)
-
failureFloodingThreshold
public long failureFloodingThreshold()
Description copied from interface:FailureHandlerWhen this handler is used for handling mass indexing failures - returns the number of failures during one mass indexing beyond which the failure handler will no longer be notified. This threshold is reached separately for each indexed type. Otherwise, i.e. not in the context of mass indexing, this value is ignored.May be overridden by mass indexer parameters (see
failureFloodingThreshold(long)in theMassIndexerinterface).- Specified by:
failureFloodingThresholdin interfaceFailureHandler
-
-