public class ExternalStorageRebalancer extends Object implements org.apache.kafka.clients.consumer.ConsumerRebalanceListener
| Modifier and Type | Method and Description |
|---|---|
void |
onPartitionsAssigned(Collection<org.apache.kafka.common.TopicPartition> partitions)
Get the offset of the new partition from the external store.
|
void |
onPartitionsRevoked(Collection<org.apache.kafka.common.TopicPartition> partitions)
Save the offset of the current partition in the external store.
|
static ExternalStorageRebalancer |
rebalanceListener(org.apache.kafka.clients.consumer.Consumer consumer,
ExternalOffsetStorage externalOffsetStorage) |
public static ExternalStorageRebalancer rebalanceListener(org.apache.kafka.clients.consumer.Consumer consumer, ExternalOffsetStorage externalOffsetStorage)
public void onPartitionsAssigned(Collection<org.apache.kafka.common.TopicPartition> partitions)
onPartitionsAssigned in interface org.apache.kafka.clients.consumer.ConsumerRebalanceListenerpartitions - Partitions assigned that used to re-set the consumers.public void onPartitionsRevoked(Collection<org.apache.kafka.common.TopicPartition> partitions)
onPartitionsRevoked in interface org.apache.kafka.clients.consumer.ConsumerRebalanceListenerpartitions - Partitions that were revoked to save the offsets of.Copyright © 2017 Grakn Labs Ltd. All rights reserved.