public class AmqpMessageHeaderErrorMessageStrategy extends Object implements ErrorMessageStrategy
ErrorMessageStrategy
extension that adds the raw AMQP message as
a header to the ErrorMessage
.Modifier and Type | Field and Description |
---|---|
static String |
AMQP_RAW_MESSAGE
Header name/retry context variable for the raw received message.
|
Constructor and Description |
---|
AmqpMessageHeaderErrorMessageStrategy() |
Modifier and Type | Method and Description |
---|---|
ErrorMessage |
buildErrorMessage(Throwable throwable,
AttributeAccessor context)
Build the error message.
|
public static final String AMQP_RAW_MESSAGE
public AmqpMessageHeaderErrorMessageStrategy()
public ErrorMessage buildErrorMessage(Throwable throwable, @Nullable AttributeAccessor context)
ErrorMessageStrategy
buildErrorMessage
in interface ErrorMessageStrategy
throwable
- the payload.context
- the attributes.