Exception in thread "main" joptsimple.UnrecognizedOptionException: zookeeper is not a recognized option

在创建主题时,

在较新版本(2.2 及更高版本)的 Kafka 不再需要 ZooKeeper 连接字符串,即- -zookeeper localhost:2181。使用 Kafka Broker的 --bootstrap-server localhost:9092来替代- -zookeeper localhost:2181。

即使用命令:

bin/kafka-topics.sh --create --bootstrap-server localhost:9092 --replication-factor 1 --partitions 1 --topic test

替代命令:

bin/kafka-topics.sh --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic test
///纵有疾风起,人生不言弃///
原文地址:https://www.cnblogs.com/skzxc/p/15709493.html