Interface ContainerAwareBatchErrorHandler

All Superinterfaces:
BatchErrorHandler, ConsumerAwareBatchErrorHandler, GenericErrorHandler<org.apache.kafka.clients.consumer.ConsumerRecords<?,?>>
All Known Subinterfaces:
ListenerInvokingBatchErrorHandler
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@Deprecated @FunctionalInterface public interface ContainerAwareBatchErrorHandler extends ConsumerAwareBatchErrorHandler
Deprecated.
in favor of CommonErrorHandler.
An error handler that has access to the batch of records from the last poll the consumer, and the container.
Since:
2.1
Author:
Gary Russell
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    handle(Exception thrownException, org.apache.kafka.clients.consumer.ConsumerRecords<?,?> data, org.apache.kafka.clients.consumer.Consumer<?,?> consumer)
    Deprecated.
    Handle the exception.
    void
    handle(Exception thrownException, org.apache.kafka.clients.consumer.ConsumerRecords<?,?> data, org.apache.kafka.clients.consumer.Consumer<?,?> consumer, MessageListenerContainer container)
    Deprecated.
    Handle the exception.
    default void
    handle(Exception thrownException, org.apache.kafka.clients.consumer.ConsumerRecords<?,?> data, org.apache.kafka.clients.consumer.Consumer<?,?> consumer, MessageListenerContainer container, Runnable invokeListener)
    Deprecated.
    Handle the exception.

    Methods inherited from interface org.springframework.kafka.listener.ConsumerAwareBatchErrorHandler

    handle

    Methods inherited from interface org.springframework.kafka.listener.GenericErrorHandler

    clearThreadState, isAckAfterHandle, setAckAfterHandle
  • Method Details

    • handle

      default void handle(Exception thrownException, @Nullable org.apache.kafka.clients.consumer.ConsumerRecords<?,?> data, org.apache.kafka.clients.consumer.Consumer<?,?> consumer)
      Deprecated.
      Description copied from interface: GenericErrorHandler
      Handle the exception.
      Specified by:
      handle in interface ConsumerAwareBatchErrorHandler
      Specified by:
      handle in interface GenericErrorHandler<org.apache.kafka.clients.consumer.ConsumerRecords<?,?>>
      Parameters:
      thrownException - The exception.
      data - the data.
      consumer - the consumer.
    • handle

      void handle(Exception thrownException, @Nullable org.apache.kafka.clients.consumer.ConsumerRecords<?,?> data, org.apache.kafka.clients.consumer.Consumer<?,?> consumer, MessageListenerContainer container)
      Deprecated.
      Description copied from interface: BatchErrorHandler
      Handle the exception.
      Specified by:
      handle in interface BatchErrorHandler
      Specified by:
      handle in interface ConsumerAwareBatchErrorHandler
      Parameters:
      thrownException - the exception.
      data - the consumer records.
      consumer - the consumer.
      container - the container.
    • handle

      default void handle(Exception thrownException, @Nullable org.apache.kafka.clients.consumer.ConsumerRecords<?,?> data, org.apache.kafka.clients.consumer.Consumer<?,?> consumer, MessageListenerContainer container, @Nullable Runnable invokeListener)
      Deprecated.
      Handle the exception.
      Specified by:
      handle in interface BatchErrorHandler
      Parameters:
      thrownException - the exception.
      data - the consumer records.
      consumer - the consumer.
      container - the container.
      invokeListener - a callback to re-invoke the listener.
      Since:
      2.3.7