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

John Roesler commented on KAFKA-9274:
-------------------------------------

Yep, something like that is what I would propose, although, I'd personally 
advocate for something like:

{noformat}
while running:
  poll
  for each task:
    if not initialized, try to initialize
    if initialized and not commit needed:
       try to do some work
    if commit needed:
       try to commit (if commit succeeds, set commit needed := false)
{noformat}

Clearly, it's more complex than that, but hopefully this conveys the general 
idea of not letting tasks block each other, and attempting to continue making 
whatever progress we can on each task, regardless of what state the other tasks 
are in.

> Gracefully handle timeout exceptions on Kafka Streams
> -----------------------------------------------------
>
>                 Key: KAFKA-9274
>                 URL: https://issues.apache.org/jira/browse/KAFKA-9274
>             Project: Kafka
>          Issue Type: Improvement
>          Components: streams
>            Reporter: Boyang Chen
>            Priority: Major
>
> Right now streams don't treat timeout exception as retriable in general by 
> throwing it to the application level. If not handled by the user, this would 
> kill the stream thread unfortunately.
> In fact, timeouts happen mostly due to network issue or server side 
> unavailability. Hard failure on client seems to be an over-kill.
> We would like to discuss what's the best practice to handle timeout 
> exceptions on Streams. The current state is still brainstorming and 
> consolidate all the cases that contain timeout exception within this ticket.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to