public final class KafkaConsumerMetaTable extends Object
| Constructor and Description |
|---|
KafkaConsumerMetaTable(MetricsTable metaTable) |
| Modifier and Type | Method and Description |
|---|---|
long |
get(TopicPartition topicPartition)
Gets the offset of a given topic partition.
|
void |
save(Map<TopicPartition,Long> offsets) |
public KafkaConsumerMetaTable(MetricsTable metaTable)
public void save(Map<TopicPartition,Long> offsets) throws Exception
Exceptionpublic long get(TopicPartition topicPartition) throws Exception
topicPartition - The topic and partition to fetch offset.-1 if the offset is not found.Exception - If there is an error when fetching.Copyright © 2015 Cask Data, Inc. Licensed under the Apache License, Version 2.0.