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

ASF GitHub Bot commented on KAFKA-6768:
---------------------------------------

hachikuji opened a new pull request #4842: KAFKA-6768; Transactional producer 
may hang in close with pending requests
URL: https://github.com/apache/kafka/pull/4842
 
 
   This patch fixes an edge case in producer shutdown which prevents `close()` 
from completing due to a pending request which will never be sent due to 
shutdown initiation. I have added a test case which reproduces the scenario.
   
   ### Committer Checklist (excluded from commit message)
   - [ ] Verify design and implementation 
   - [ ] Verify test coverage and CI build status
   - [ ] Verify documentation (including upgrade notes)
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Producer may hang in close with pending transaction
> ---------------------------------------------------
>
>                 Key: KAFKA-6768
>                 URL: https://issues.apache.org/jira/browse/KAFKA-6768
>             Project: Kafka
>          Issue Type: Bug
>          Components: producer 
>            Reporter: Jason Gustafson
>            Assignee: Jason Gustafson
>            Priority: Major
>             Fix For: 1.1.1
>
>
> There is an edge case for transactional producers which will cause close() to 
> hang indefinitely (unless used with a timeout). Say, for example, that the 
> producer is trying to send an AddPartitionsToTxn request to the broker. Upon 
> shutdown, the Sender's running flag will be set to false and we will begin 
> graceful shutdown. Graceful shutdown will not complete, however, until we can 
> send the AddPartitionsToTxn request. But the latter is blocked by the fact 
> that the running flag is disabled. So no progress can be made and shutdown 
> cannot complete.



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

Reply via email to