Interface | Description |
---|---|
Consumer<K,V> | |
ConsumerRebalanceListener |
A callback interface that the user can implement to trigger custom actions when the set of partitions assigned to the
consumer changes.
|
OffsetCommitCallback |
A callback interface that the user can implement to trigger custom actions when a commit request completes.
|
Class | Description |
---|---|
ConsumerConfig |
The consumer configuration keys
|
ConsumerRecord<K,V> |
A key/value pair to be received from Kafka.
|
ConsumerRecords<K,V> |
A container that holds the list
ConsumerRecord per partition for a
particular topic. |
KafkaConsumer<K,V> |
A Kafka client that consumes records from a Kafka cluster.
|
MockConsumer<K,V> |
A mock of the
Consumer interface you can use for testing code that uses Kafka. |
OffsetAndMetadata |
The Kafka offset commit API allows users to provide additional metadata (in the form of a string)
when an offset is committed.
|
RangeAssignor |
The range assignor works on a per-topic basis.
|
RoundRobinAssignor |
The roundrobin assignor lays out all the available partitions and all the available consumers.
|
Enum | Description |
---|---|
OffsetResetStrategy |
Exception | Description |
---|---|
CommitFailedException |
This exception is raised when an offset commit with
KafkaConsumer.commitSync() fails
with an unrecoverable error. |
InvalidOffsetException |
Thrown when the offset for a set of partitions is invalid (either undefined or out of range),
and no reset policy has been configured.
|
NoOffsetForPartitionException |
Indicates that there is no stored offset for a partition and no defined offset
reset policy.
|
OffsetOutOfRangeException |
No reset policy has been defined, and the offsets for these partitions are either larger or smaller
than the range of offsets the server has for the given partition.
|