[
https://issues.apache.org/jira/browse/KAFKA-3191?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Ewen Cheslack-Postava updated KAFKA-3191:
-----------------------------------------
Resolution: Fixed
Fix Version/s: 0.9.1.0
0.9.0.1
Status: Resolved (was: Patch Available)
Issue resolved by pull request 850
[https://github.com/apache/kafka/pull/850]
> Improve offset committing JavaDoc in KafkaConsumer
> --------------------------------------------------
>
> Key: KAFKA-3191
> URL: https://issues.apache.org/jira/browse/KAFKA-3191
> Project: Kafka
> Issue Type: Improvement
> Components: consumer
> Affects Versions: 0.9.0.0
> Reporter: Adam Kunicki
> Assignee: Adam Kunicki
> Priority: Minor
> Labels: documentation
> Fix For: 0.9.0.1, 0.9.1.0
>
>
> http://www.confluent.io/blog/tutorial-getting-started-with-the-new-apache-kafka-0.9-consumer-client
> includes some great examples of how to manage offset commits in Kafka 0.9.
> It is currently unclear from the JavaDoc that the following is expected:
> {code}
> consumer.commitSync(Collections.singletonMap(record.partition(), new
> OffsetAndMetadata(record.offset() + 1)));
> {code}
> The committed offset should always be the offset of the next message that
> your application will read.
> This information should be incorporated into the existing JavaDoc to make it
> clearer.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)