kafka配置规范
kafka使用规范:
安装参考链接
https://www.cnblogs.com/alvingofast/p/kafka_deployment_on_windows.html
https://blog.csdn.net/weixin_37770023/article/details/81807942zookeeper启动
zkserver 启动 zookeeperkafka启动
cd D:\kafka\kafka_2.11-2.1.1
输入:
.\bin\windows\kafka-server-start.bat .\config\server.properties测试kafka服务:
cmd 命令下:
创建一个topics:
cd D:\kafka\kafka_2.11-2.1.1\bin\windows
输入: kafka-topics.bat --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic test
打开一个produce:
cd D:\kafka\kafka_2.11-2.1.1\bin\windows
输入: kafka-console-producer.bat --broker-list localhost:9092 --topic test
打开一个consumer:
cd D:\kafka\kafka_2.11-2.1.1\bin\windows
输入:kafka-console-consumer.bat --bootstrap-server localhost:9092 --topic testproduce 输入字符,consumer就可以接收到字符。
文章标题:kafka配置规范
发布时间:2021-04-21, 22:40:30
最后更新:2021-04-21, 22:27:34