[ 
https://issues.apache.org/jira/browse/KAFKA-4600?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16812168#comment-16812168
 ] 

Braedon Vickers commented on KAFKA-4600:
----------------------------------------

Hi [~guozhang],

Sounds like we are on the same page about the issue itself now, which is great 
:)

Option 1 in your comment seems sufficient to me - it's certainly the simpler 
option of the two.

I'm not up on the meta around when KIPs need to be used, but this seems like a 
pretty basic (but important) bug fix to me, rather than a breaking change to 
functionality. Are people _really_ expecting uncaught exceptions thrown by 
`ConsumerRebalanceListener` methods to be (effectively) ignored, and relying 
intentionally/specifically on that behaviour for their implementations?

I'm sure there will be implementations that are silently failing currently 
(like mine was before I spotted and worked around the issue) that will fail 
loudly after this is fixed; all the more reason to patch this as a bug. As 
noted in the original issue, this can easily cause data corruption or data loss.

Braedon

> Consumer proceeds on when ConsumerRebalanceListener fails
> ---------------------------------------------------------
>
>                 Key: KAFKA-4600
>                 URL: https://issues.apache.org/jira/browse/KAFKA-4600
>             Project: Kafka
>          Issue Type: Bug
>          Components: consumer
>    Affects Versions: 0.10.1.1
>            Reporter: Braedon Vickers
>            Priority: Major
>
> One of the use cases for a ConsumerRebalanceListener is to load state 
> necessary for processing a partition when it is assigned. However, when 
> ConsumerRebalanceListener.onPartitionsAssigned() fails for some reason (i.e. 
> the state isn't loaded), the error is logged and the consumer proceeds on as 
> if nothing happened, happily consuming messages from the new partition. When 
> the state is relied upon for correct processing, this can be very bad, e.g. 
> data loss can occur.
> It would be better if the error was propagated up so it could be dealt with 
> normally. At the very least the assignment should fail so the consumer 
> doesn't see any messages from the new partitions, and the rebalance can be 
> reattempted.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to