Return-Path: X-Original-To: apmail-kafka-dev-archive@www.apache.org Delivered-To: apmail-kafka-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E58E59517 for ; Wed, 9 Jan 2013 16:50:12 +0000 (UTC) Received: (qmail 36590 invoked by uid 500); 9 Jan 2013 16:50:12 -0000 Delivered-To: apmail-kafka-dev-archive@kafka.apache.org Received: (qmail 36546 invoked by uid 500); 9 Jan 2013 16:50:12 -0000 Mailing-List: contact dev-help@kafka.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@kafka.apache.org Delivered-To: mailing list dev@kafka.apache.org Received: (qmail 36537 invoked by uid 99); 9 Jan 2013 16:50:12 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 Jan 2013 16:50:12 +0000 Date: Wed, 9 Jan 2013 16:50:12 +0000 (UTC) From: "Neha Narkhede (JIRA)" To: dev@kafka.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Resolved] (KAFKA-690) TopicMetadataRequest throws exception when no topics are specified MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/KAFKA-690?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Neha Narkhede resolved KAFKA-690. --------------------------------- Resolution: Fixed Assignee: David Arthur > TopicMetadataRequest throws exception when no topics are specified > ------------------------------------------------------------------ > > Key: KAFKA-690 > URL: https://issues.apache.org/jira/browse/KAFKA-690 > Project: Kafka > Issue Type: Bug > Components: core > Affects Versions: 0.8 > Reporter: David Arthur > Assignee: David Arthur > Fix For: 0.8 > > Attachments: KAFKA-690.patch > > > If no topics are sent in a TopicMetadataRequest, `readFrom` throws an exception when trying to get the the head of the topic list for a debug statement. > java.util.NoSuchElementException: head of empty list > at scala.collection.immutable.Nil$.head(List.scala:386) > at scala.collection.immutable.Nil$.head(List.scala:383) > at kafka.api.TopicMetadataRequest$$anonfun$readFrom$2.apply(TopicMetadataRequest.scala:43) > at kafka.api.TopicMetadataRequest$$anonfun$readFrom$2.apply(TopicMetadataRequest.scala:43) > at kafka.utils.Logging$class.debug(Logging.scala:51) > at kafka.api.TopicMetadataRequest$.debug(TopicMetadataRequest.scala:25) > at kafka.api.TopicMetadataRequest$.readFrom(TopicMetadataRequest.scala:43) > at kafka.api.RequestKeys$$anonfun$4.apply(RequestKeys.scala:37) > at kafka.api.RequestKeys$$anonfun$4.apply(RequestKeys.scala:37) > at kafka.network.RequestChannel$Request.(RequestChannel.scala:47) > at kafka.network.Processor.read(SocketServer.scala:320) > at kafka.network.Processor.run(SocketServer.scala:231) > at java.lang.Thread.run(Thread.java:680) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira