[ https://issues.apache.org/jira/browse/KAFKA-6571?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Matthias J. Sax resolved KAFKA-6571. ------------------------------------ Resolution: Duplicate KIP-367 add `close(Duration)` with new non-blocking semantics: [https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=89070496] Closing this. > KafkaProducer.close(0) should be non-blocking > --------------------------------------------- > > Key: KAFKA-6571 > URL: https://issues.apache.org/jira/browse/KAFKA-6571 > Project: Kafka > Issue Type: Bug > Reporter: Dong Lin > Assignee: Ahmed Al-Mehdi > Priority: Major > > According to the Java doc of producer.close(long timeout, TimeUnit timeUnit), > it is said that "Specifying a timeout of zero means do not wait for pending > send requests to complete". However, producer.close(0) can currently block on > waiting for the sender thread to exit, which in turn can block on user's > callback. > We probably should not let producer.close(0) join the sender thread if user > has specified zero timeout. -- This message was sent by Atlassian Jira (v8.3.4#803005)