[ https://issues.apache.org/jira/browse/KAFKA-4234?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15536715#comment-15536715 ]
ASF GitHub Bot commented on KAFKA-4234: --------------------------------------- GitHub user vahidhashemian opened a pull request: https://github.com/apache/kafka/pull/1944 KAFKA-4234: Temporarily disable committing offsets in consumer's `unsubscribe()` Temporarily disable the offset commit (when auto commit is enabled) in the new consumer's `unsubscribe()` method towards a workaround for the issue reported in [KAFKA-3491](https://issues.apache.org/jira/browse/KAFKA-3491). For now, a call to `unsubscribe()` can be made to reset the offsets in case processing the batch received from the most recent `poll()` is interrupted (due to some exception). You can merge this pull request into a Git repository by running: $ git pull https://github.com/vahidhashemian/kafka KAFKA-4234 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/kafka/pull/1944.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1944 ---- commit 6e850b65904031cb4f8c21834d10cd746cc62f42 Author: Vahid Hashemian <vahidhashem...@us.ibm.com> Date: 2016-09-30T18:36:22Z KAFKA-4234: Temporarily disable committing offsets in consumer's unsubscribe() Temporarily disable the offset commit (when auto commit is enabled) in the new consumer's `unsubscribe()` method towards a workaround for the issue reported in [KAFKA-3491](https://issues.apache.org/jira/browse/KAFKA-3491). For now, a call to `unsubscribe()` can be made to reset the offsets in case processing the batch received from the most recent `poll()` is interrupted (due to some exception). ---- > Consumer should not commit offsets in unsubscribe() > --------------------------------------------------- > > Key: KAFKA-4234 > URL: https://issues.apache.org/jira/browse/KAFKA-4234 > Project: Kafka > Issue Type: Bug > Components: consumer > Reporter: Jason Gustafson > Assignee: Vahid Hashemian > Fix For: 0.10.1.0 > > > In KIP-70, we changed the behavior of {{unsubscribe}} to commit offsets if > autocommit is enabled. Unfortunately, because of the issue documented in > KAFKA-3491, this makes it impossible to abort processing if an exception is > thrown while processing some records. Until we have a fix for this problem, > we should probably revert this behavior. -- This message was sent by Atlassian JIRA (v6.3.4#6332)