Interface ErrorHandler<T>


public interface ErrorHandler<T>
Interface for handling errors. If the error handler completes normally, the message or messages will be considered recovered for further processing purposes. If the message should not be considered recovered, an exception must be thrown from the error handler.
Since:
3.0
Author:
Tomaz Fernandes
  • Method Details

    • handle

      default void handle(Message<T> message, Throwable t)
      Handle errors thrown when processing a Message.
      Parameters:
      message - the message.
      t - the thrown exception.
    • handle

      default void handle(Collection<Message<T>> messages, Throwable t)
      Handle errors thrown when processing a batch of Messages.
      Parameters:
      messages - the messages.
      t - the thrown exception.