In this video will will see how to Install and Run Kafka? And also learn to create a topic, Produce and Consumer Kafka message.
Download link -
kafka.apache.o...
#javacodingskills #runkafka #installkafka #sendkafkamessage #consumekafkamessage #kafka #kafkatutorial #springbatch #springboot
Commands-
Commands to run Kafa and all
--------------------------------------------------
goto kafka home directory-
C:\software\kafka_2.11-2.3.1
Note: Kafka home may different in your machine as per you installation change it accordingly
.\bin\windows\zookeeper-server-start.bat .\config\zookeeper.properties
.\bin\windows\kafka-server-start.bat .\config\server.properties
Crate topics-
go to window folder
C:\software\kafka_2.11-2.3.1\bin\windows
kafka-topics.bat --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic TOPIC_TEST
kafka-topics.bat --list --bootstrap-server localhost:9092
Producer-
C:\software\kafka_2.11-2.3.1\bin\windows
kafka-console-producer.bat --broker-list localhost:9092 --topic TOPIC_TEST
consumer-
C:\software\kafka_2.11-2.3.1\bin\windows
kafka-console-consumer.bat --bootstrap-server localhost:9092 --topic TOPIC_TEST --from-beginning
On mac-
sh bin/zookeeper-server-start.sh config/zookeeper.properties
sh bin/kafka-server-start.sh config/server.properties
Негізгі бет How to Install and Run Kafka? | Produce and Consumer Kafka message.
Пікірлер: 5