i have already started to learn Kafka. Trying basic operations on it. I have stucked on a point which about the \'Brokers\'.
My kafka is running but when i want to
Don't know if this answer is still relevant but recently resolved this same problem in a VBox VM broker not reachable from host Windows OS. Since you have mentioned bootsrap_servers in KafkaConsumer, I assume you are using at least kafka 0.10.0.0
Please look for the advertised.listeners property in server.properties file and set it to PLAINTEXT://localhost:9092 or PLAINTEXT://
But before you set that make sure your broker is reachable from the environment where your consumer is running (by doing ping localhost).
Also, you need to restart the kafka-server and consumer/producer (whatever is running) and try sending/receiving.
For example, if you are running VM, you may like to use Host-only adapter to make the broker reachable from host machine
NOTE: This configuration works for Kafka Server >= 0.10.X.X but not for 0.8.2.X. Haven't checked for 0.9.0.X