I am programming a client to work with kafka 0.9. I want to know how to create a topic. This answer: How to create a Topic in Kafka through Java is similar to what I am aski
I tried following Soon Chee Loong's answer with Kafka 0.9.0.1 but had to make one change. ZKStringSerializer is now private. To create ZkUtils I used the following API (it creates a ZkClient internally):
ZkUtils.apply(
"zookeeper1:port1,zookeeper2:port2",
sessionTimeoutMs,
connectionTimeoutMs,
false)