Consumer¶
Consumer<K, V>
is an interface to KafkaConsumer for Kafka developers to use to consume records (with K
keys and V
values) from a Kafka cluster.
Contract (Subset)¶
enforceRebalance¶
void enforceRebalance()
groupMetadata¶
ConsumerGroupMetadata groupMetadata()
Subscribing to Topics¶
void subscribe(
Collection<String> topics)
void subscribe(
Collection<String> topics,
ConsumerRebalanceListener callback)
void subscribe(
Pattern pattern)
void subscribe(
Pattern pattern,
ConsumerRebalanceListener callback)
Waking Up¶
void wakeup()