Mike Bridge created KAFKA-2286:
----------------------------------
Summary: Cannot produce messages remotely: No partition metadata
for topic test due to kafka.common.LeaderNotAvailableException
Key: KAFKA-2286
URL: https://issues.apache.org/jira/browse/KAFKA-2286
Project: Kafka
Issue Type: Bug
Components: producer
Affects Versions: 0.8.2.1
Environment: CentOS 7 / Oracle jdk1.8.0_45
Reporter: Mike Bridge
Assignee: Jun Rao
Priority: Critical
I successfully ran the QuickStart tutorial locally on a single EC2 machine. I
stopped everything running on the server, deleted the logs in /tmp, and added
the single line "advertised.host.name=MY.EXTERNAL.IP" to server.properties.
(Port 9092 is indeed allowed through the firewall and responding, so no problem
there.)
I then restarted the server and successfully created a topic as per the
QuickStart tutorial.
Then, I ran the producer in exactly the same way as in the QuickStart tutorial,
except on a remote machine:
bin/kafka-console-producer.sh --broker-list MY.EXTERNAL.IP:9092 --topic
test
This generates the following error:
WARN Error while fetching metadata [{TopicMetadata for topic test123 -> No
partition metadata for topic test123 due to
kafka.common.LeaderNotAvailableException}] for topic [test123]: class
kafka.common.LeaderNotAvailableException (kafka.producer.BrokerPartitionInfo)
See also:
http://stackoverflow.com/questions/30880811/kafka-quickstart-advertised-host-name-gives-kafka-common-leadernotavailableexce/30919109#30919109
I've spent several evenings trying to get this simple Kafka setup to work but
am stuck. It seems like it should work.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)