abstract fun assign(topicPartition: TopicPartition): KafkaConsumer<K, V>
Manually assign a partition to this consumer.
topicPartition - partition which want assigned
Return
current KafkaConsumer instance
abstract fun assign(topicPartitions: MutableSet<TopicPartition>): KafkaConsumer<K, V>
Manually assign a list of partition to this consumer.
topicPartitions - partitions which want assigned
Return
current KafkaConsumer instance
abstract fun assign(topicPartition: TopicPartition, completionHandler: Handler<AsyncResult<Void>>): KafkaConsumer<K, V>
Manually assign a partition to this consumer.
Due to internal buffering of messages, when reassigning the old partition may remain in effect (as observed by the #handler(Handler) record handler)} until some time after the given completionHandler is called. In contrast, the once the given completionHandler is called the #batchHandler(Handler) will only see messages consistent with the new partition.
topicPartition - partition which want assigned
completionHandler - handler called on operation completed
Return
current KafkaConsumer instance
abstract fun assign(topicPartitions: MutableSet<TopicPartition>, completionHandler: Handler<AsyncResult<Void>>): KafkaConsumer<K, V>
Manually assign a list of partition to this consumer.
Due to internal buffering of messages, when reassigning the old set of partitions may remain in effect (as observed by the #handler(Handler) record handler)} until some time after the given completionHandler is called. In contrast, the once the given completionHandler is called the #batchHandler(Handler) will only see messages consistent with the new set of partitions.
topicPartitions - partitions which want assigned
completionHandler - handler called on operation completed
Return
current KafkaConsumer instance