...
These APIs allow for centralized management of offsets. Read more Offset Management. As per comments on KAFKA-993 these API calls are not functional in Kafka 0.8 and will be implemented in a future version.
Consumer Metadata Request
The offsets for a given consumer group are maintained by a specific broker called the offset coordinator. i.e., a consumer needs to issue its offset commit and fetch requests to this specific broker. It can discover the current offset coordinator by issuing a consumer metadata request.
Code Block |
---|
ConsumerMetadataRequest => ConsumerGroup
ConsumerGroup => string |
Consumer Metadata Response
On a successful (ErrorCode == 0) response, the coordinator fields provide the id/host/port details of the offset coordinator.
Code Block |
---|
ConsumerMetadataResponse => ErrorCode [CoordinatorId CoordinatorHost CoordinatorPort]
ErrorCode => int16
CoordinatorId => int32
CoordinatorHost => string
CoordinatorPort => int32 |
Offset Commit Request
Code Block |
---|
OffsetCommitRequest => ConsumerGroup [TopicName [Partition Offset Metadata]] ConsumerGroup => string TopicName => string Partition => int32 Offset => int64 Metadata => string |
...