Class ConditionalRejectingErrorHandler.DefaultExceptionStrategy
- java.lang.Object
-
- org.springframework.amqp.rabbit.listener.ConditionalRejectingErrorHandler.DefaultExceptionStrategy
-
- All Implemented Interfaces:
FatalExceptionStrategy
- Enclosing class:
- ConditionalRejectingErrorHandler
public static class ConditionalRejectingErrorHandler.DefaultExceptionStrategy extends java.lang.Object implements FatalExceptionStrategy
Default implementation ofFatalExceptionStrategy.- Since:
- 1.6.3
-
-
Field Summary
Fields Modifier and Type Field Description protected org.apache.commons.logging.Loglogger
-
Constructor Summary
Constructors Constructor Description DefaultExceptionStrategy()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisFatal(java.lang.Throwable t)protected booleanisUserCauseFatal(java.lang.Throwable cause)Subclasses can override this to add custom exceptions.protected voidlogFatalException(ListenerExecutionFailedException t, java.lang.Throwable cause)Log the fatal ListenerExecutionFailedException at WARN level, excluding stack trace.
-
-
-
Method Detail
-
isFatal
public boolean isFatal(java.lang.Throwable t)
- Specified by:
isFatalin interfaceFatalExceptionStrategy
-
logFatalException
protected void logFatalException(ListenerExecutionFailedException t, java.lang.Throwable cause)
Log the fatal ListenerExecutionFailedException at WARN level, excluding stack trace. Subclasses can override this behavior.- Parameters:
t- theListenerExecutionFailedException.cause- the root cause (skipping any generalMessagingExceptions).- Since:
- 2.2.4
-
isUserCauseFatal
protected boolean isUserCauseFatal(java.lang.Throwable cause)
Subclasses can override this to add custom exceptions.- Parameters:
cause- the cause- Returns:
- true if the cause is fatal.
-
-