public class KafkaReader<K,V> extends Object implements Runnable
Constructor and Description |
---|
KafkaReader(String topic,
int numPartitions,
org.apache.kafka.clients.consumer.Consumer<K,V> consumer,
io.confluent.security.store.KeyValueStore<K,V> cache,
ConsumerListener<K,V> consumerListener,
StatusListener statusListener,
KafkaStoreConfig storeConfig,
org.apache.kafka.common.utils.Time time) |
Modifier and Type | Method and Description |
---|---|
void |
close(Duration closeTimeout) |
CompletableFuture<Void> |
existingRecordsFuture()
Returns future that completes when existing records on all partitions at the time
the KafkaReader was started are processed and available in the cache.
|
void |
run() |
CompletionStage<Void> |
start(Duration topicCreateTimeout) |
public KafkaReader(String topic, int numPartitions, org.apache.kafka.clients.consumer.Consumer<K,V> consumer, io.confluent.security.store.KeyValueStore<K,V> cache, ConsumerListener<K,V> consumerListener, StatusListener statusListener, KafkaStoreConfig storeConfig, org.apache.kafka.common.utils.Time time)
public CompletionStage<Void> start(Duration topicCreateTimeout)
public CompletableFuture<Void> existingRecordsFuture()
public void close(Duration closeTimeout)