SubscriptionState allows for tracking the topics, partitions, and offsets assigned to a Kafka consumer.

SubscriptionState is in partitionsAutoAssigned if it is AUTO_TOPICS or AUTO_PATTERN.

Table 1. SubscriptionState’s Internal Properties (e.g. Registries, Counters and Flags)
Name Description


ConsumerRebalanceListener for notifications about partition assignment changes

Used exclusively when ConsumerCoordinator is notified about:

subscribe Method

void subscribe(Pattern pattern, ConsumerRebalanceListener listener)


subscribe is used exclusively when KafkaConsumer is requested to subscribe to the topics that match a pattern with a ConsumerRebalanceListener.

results matching ""

    No results matching ""