Class PartitionPausingBackoffManager

java.lang.Object
org.springframework.kafka.listener.PartitionPausingBackoffManager
All Implemented Interfaces:
EventListener, ApplicationListener<ListenerContainerPartitionIdleEvent>, KafkaConsumerBackoffManager

public class PartitionPausingBackoffManager extends Object implements KafkaConsumerBackoffManager, ApplicationListener<ListenerContainerPartitionIdleEvent>
A manager that backs off consumption for a given topic if the timestamp provided is not due. Use with SeekToCurrentErrorHandler to guarantee that the message is read again after partition consumption is resumed (or seek it manually by other means). It's also necessary to set a ContainerProperties.setIdlePartitionEventInterval(Long) so the Manager can resume the partition consumption. Note that when a record backs off the partition consumption gets paused for approximately that amount of time, so you must have a fixed backoff value per partition.
Since:
2.7
Author:
Tomaz Fernandes, Gary Russell
See Also:
  • SeekToCurrentErrorHandler