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

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

GitHub user hachikuji opened a pull request:

    https://github.com/apache/kafka/pull/581

    KAFKA-2880: consumer should handle disconnect/timeout for metadata requests

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/hachikuji/kafka KAFKA-2880

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/kafka/pull/581.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 #581
    
----
commit 605641249dc289ae7e8d7e003cd0e1f35367abad
Author: Jason Gustafson <ja...@confluent.io>
Date:   2015-11-24T01:45:32Z

    KAFKA-2880: consumer should handle disconnect/timeout for metadata requests

commit 851c9b3877b337c83e88f4c4100383129f83222c
Author: Jason Gustafson <ja...@confluent.io>
Date:   2015-11-24T17:40:00Z

    additional error handling/test cases for topic metadata API

----


> Fetcher.getTopicMetadata NullPointerException when broker cannot be reached
> ---------------------------------------------------------------------------
>
>                 Key: KAFKA-2880
>                 URL: https://issues.apache.org/jira/browse/KAFKA-2880
>             Project: Kafka
>          Issue Type: Bug
>          Components: clients
>    Affects Versions: 0.9.0.0
>            Reporter: Ewen Cheslack-Postava
>            Assignee: Jason Gustafson
>
> The Fetcher class will throw a NullPointerException if a broker cannot be 
> reached:
> {quote}
> Exception in thread "main" java.lang.NullPointerException
>         at 
> org.apache.kafka.common.requests.MetadataResponse.<init>(MetadataResponse.java:130)
>         at 
> org.apache.kafka.clients.consumer.internals.Fetcher.getTopicMetadata(Fetcher.java:203)
>         at 
> org.apache.kafka.clients.consumer.KafkaConsumer.partitionsFor(KafkaConsumer.java:1143)
>         at 
> org.apache.kafka.connect.util.KafkaBasedLog.start(KafkaBasedLog.java:126)
>         at 
> org.apache.kafka.connect.storage.KafkaOffsetBackingStore.start(KafkaOffsetBackingStore.java:85)
>         at org.apache.kafka.connect.runtime.Worker.start(Worker.java:108)
>         at org.apache.kafka.connect.runtime.Connect.start(Connect.java:56)
>         at 
> org.apache.kafka.connect.cli.ConnectDistributed.main(ConnectDistributed.java:62)
> {quote}
> This is trivially reproduced by trying to start Kafka Connect in distributed 
> mode (i.e. connect-distributed.sh config/connect-distributed.properties) with 
> no broker running. However, it's not specific to Kafka Connect, it just 
> happens to use the consumer in a way that triggers it reliably.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to