Class PartitionPausingBackOffManagerFactory

    • Constructor Detail

      • PartitionPausingBackOffManagerFactory

        public PartitionPausingBackOffManagerFactory​(org.springframework.core.task.TaskExecutor timingAdjustmentManagerTaskExecutor)
        Constructs a factory instance that will create the KafkaConsumerBackoffManager instances with the provided TaskExecutor in its KafkaConsumerTimingAdjuster.
        Parameters:
        timingAdjustmentManagerTaskExecutor - the TaskExecutor to be used.
      • PartitionPausingBackOffManagerFactory

        public PartitionPausingBackOffManagerFactory​(boolean timingAdjustmentEnabled)
        Constructs a factory instance specifying whether or not timing adjustment is enabled for this factories KafkaConsumerBackoffManager.
        Parameters:
        timingAdjustmentEnabled - the KafkaConsumerTimingAdjuster to be used.
      • PartitionPausingBackOffManagerFactory

        public PartitionPausingBackOffManagerFactory()
        Constructs a factory instance with default dependencies.
      • PartitionPausingBackOffManagerFactory

        public PartitionPausingBackOffManagerFactory​(java.time.Clock clock)
        Constructs an factory instance that will create the KafkaConsumerBackoffManager with the provided Clock.
        Parameters:
        clock - the clock instance to be used.
    • Method Detail

      • setTimingAdjustmentEnabled

        public final void setTimingAdjustmentEnabled​(boolean timingAdjustmentEnabled)
        Set this property to false if you don't want the resulting KafkaBackOffManager to adjust the precision of the topics' consumption timing.
        Parameters:
        timingAdjustmentEnabled - set to false to disable timing adjustment.
      • setTaskExecutor

        public final void setTaskExecutor​(org.springframework.core.task.TaskExecutor taskExecutor)
        Sets the TaskExecutor that will be used in the KafkaConsumerTimingAdjuster.
        Parameters:
        taskExecutor - the taskExecutor to be used.
      • getDefaultClock

        protected final java.time.Clock getDefaultClock()