-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Connecting to remote Kafka server #17
Comments
I put a break point in your self._sock.connect((host, port)) and changed the host to the ip it's supposed to point to and messages look like they're being sent now. It looks like |
Check the Kafka metadata in ZooKeeper. The method If you turn on debug logging level then you'll see when the client is making a metadata request to the broker. |
Ah I see. Working now. Thanks so much for you help! |
I've been playing with your module (awesome job by the way!) with everything running locally. I now have an chance to use this with a remote kafka server but running into some problems. Perhaps you can help me.
Up to this point everything works fine, I don't see any tracebacks or any error messages on the kafka server; however, when I try and send a message
producer.send_messages('this is a test')
I get a tracebackI did a little digging with the client object
client.brokers
and saw{0: BrokerMetadata(nodeId=0, host='0.0.0.0', port=9092)}
host='0.0.0.0'
I'm not too sure why it's usinglocalhost
So I tried
and got the same traceback as before
I'm still a little new to kafka, so it's probably something trivial but the current setup I have is zookeeper and a kafka server with one broker and kafka's console consumer running on a remote box1. I'm running your module from another box2. Do I need to have something else running box2? I can telnet into box1 with the host:port with no problems. I can also take the
client
and do aclient.close()
and watch kafka on box2 tell meClosing socket connection to x.x.x.x
SoKafkaClient
is connecting to it.Both boxes are running Ubuntu 12.04, python 2.7 and Kafka 0.8
box2 has kafka 0.8
box1 has the head of your repo
The text was updated successfully, but these errors were encountered: