接口 ConsumerEventListener

  • 所有超级接口:
    java.io.Serializable

    @Public
    @Stable
    public interface ConsumerEventListener
    extends java.io.Serializable
    Listener on the consumer state changes.
    • 方法概要

      所有方法 实例方法 抽象方法 
      修饰符和类型 方法 说明
      void becameActive​(Consumer<?> consumer, int partitionId)
      Notified when the consumer group is changed, and the consumer becomes the active consumer.
      void becameInactive​(Consumer<?> consumer, int partitionId)
      Notified when the consumer group is changed, and the consumer is still inactive or becomes inactive.
    • 方法详细资料

      • becameActive

        void becameActive​(Consumer<?> consumer,
                          int partitionId)
        Notified when the consumer group is changed, and the consumer becomes the active consumer.
        参数:
        consumer - the consumer that originated the event
        partitionId - the id of the partition that became active
      • becameInactive

        void becameInactive​(Consumer<?> consumer,
                            int partitionId)
        Notified when the consumer group is changed, and the consumer is still inactive or becomes inactive.
        参数:
        consumer - the consumer that originated the event
        partitionId - the id of the partition that became inactive