I am beginner to Apache kafka. I am confused between bootstrap server and zookeeper. So please explain what is bootstrap server in kafka and How it is different from zookeeper? What does it mean to consume messages from bootstrap server or zookeeper.
You are confused because Kafka has two consumers, old and new.
You should probably use the new one, which means you only need to configure bootstrap-servers (urls of Kafka brokers you are consuming from) and no need to define zookeeper connection url.
If you use the old consumer, it requires Zookeeper to maintain its state (last message read from each partition) - so you give it a zookeeper URL (since it needs zookeeper anyway) and it uses Zookeeper to find the Kafka brokers.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With