0% found this document useful (0 votes)
6 views

Kafka Document

The document provides instructions for running Zookeeper and Kafka on a Windows system, including starting the servers and creating a Kafka topic. It details commands for listing topics, describing a specific topic, and starting both a consumer and a producer. Additionally, it includes a command for sending a CSV file to the Kafka topic.

Uploaded by

Sawkat Ali Sk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

Kafka Document

The document provides instructions for running Zookeeper and Kafka on a Windows system, including starting the servers and creating a Kafka topic. It details commands for listing topics, describing a specific topic, and starting both a consumer and a producer. Additionally, it includes a command for sending a CSV file to the Kafka topic.

Uploaded by

Sawkat Ali Sk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1

Run Zookeeper:

bin\windows\zookeeper-server-start.bat config\zookeeper.properties

Log: INFO clientPortAddress is 0.0.0.0:2181


(org.apache.zookeeper.server.quorum.QuorumPeerConfig)

Run Kafka:
bin\windows\kafka-server-start.bat config\server.properties

Log: INFO Awaiting socket connections on 0.0.0.0:9092.


(kafka.network.DataPlaneAcceptor)

Create topic:
bin\windows\kafka-topics.bat --bootstrap-server localhost:9092 --create --topic
java-test-topic --partitions 3 --replication-factor 1

Get list of topics:


bin\windows\kafka-topics.bat --bootstrap-server localhost:9092 --list

Detail/Describe topic:
bin\windows\kafka-topics.bat --bootstrap-server localhost:9092 --describe --topic
java-test-topic

Start consumer:
bin\windows\kafka-console-consumer.bat --bootstrap-server localhost:9092 --topic
java-test-topic --from-beginning

Start producer:
bin\windows\kafka-console-producer.bat --broker-list localhost:9092 --topic java-
test-topic

Sent csc file: bin\windows\kafka-console-producer.bat --broker-list localhost:9092


--topic java-test-topic <C:\Users\sawka\Downloads\student-dataset.csv

You might also like