[ https://issues.apache.org/jira/browse/KAFKA-2585?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14910055#comment-14910055 ]
ASF GitHub Bot commented on KAFKA-2585: --------------------------------------- GitHub user lindong28 opened a pull request: https://github.com/apache/kafka/pull/247 KAFKA-2585; ConsoleConsumer should not hang infinitely upon exception You can merge this pull request into a Git repository by running: $ git pull https://github.com/lindong28/kafka KAFKA-2585 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/kafka/pull/247.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 #247 ---- commit ccd6826e8ab257c56e0994414c3cffc9aca387a9 Author: Dong Lin <lindon...@gmail.com> Date: 2015-09-28T05:38:27Z KAFKA-2585; ConsoleConsumer should not hang infinitely upon exception ---- > ConsoleConsumer should not hang infinitely upon exception > --------------------------------------------------------- > > Key: KAFKA-2585 > URL: https://issues.apache.org/jira/browse/KAFKA-2585 > Project: Kafka > Issue Type: Bug > Reporter: Dong Lin > Assignee: Dong Lin > > Due to imcompatibility beween Java 1.7 and Java 1.8, if Kafka ConsoleConsumer > was compiled by Java 1.8 but run by Java 1.7, and if ConsoleConsumer has > consumer.timeout.ms in the consumer.properties, then when it timesout, it > will throw the following exception and hang infinitely. > This will cause problem for e.g. Ducktape system test, which currently runs > consumer with Java 1.7 and waits for consumer to timeout. This bug causes the > Ducktape to hang for a long time. > To prevent ConsoleConsumer to hang in case of such exception, we can wrap > try/catch around run() and do System.exit(0) at the end of main() in > ConsoleConsumer. -- This message was sent by Atlassian JIRA (v6.3.4#6332)