Skip to content

Basic structure and examples to start with kafka to your projects.

License

Notifications You must be signed in to change notification settings

Ricardo-Costa/kafka-cluster-and-control-center

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kafka Cluster & Control Center

Basic structure and examples to start with kafka to your projects.

All Services

Zookeeper(cluster), Kafka(cluster), Control Center and Kafka Topics Generator

All Services

Others

Create Topic by command line

Access container:

docker exec -ti kafka-1 bash

Run command to create:

kafka-topics --create --bootstrap-server kafka-2:29092 --replication-factor 3 --partitions 3 --topic mytopic

Run command to list:

kafka-topics --list --bootstrap-server kafka-2:29092

Run command to show topic details:

kafka-topics --describe --bootstrap-server kafka-2:29092 --topic mytopic

Topic details


Test Producer by command line

Connect to topic:

kafka-console-producer --broker-list kafka-2:29092 --topic mytopic

Producer Sending


Test Consumer by command line

Connect to topic:

kafka-console-consumer --bootstrap-server kafka-2:29092 --topic mytopic

Consumer Receiving

Connect to topic with Consumer Group:

kafka-console-consumer --bootstrap-server kafka-2:29092 --topic mytopic --from-beginning --group a

Show Consumer Group details:

kafka-consumer-groups --group a --bootstrap-server kafka-2:29092 --describe

Consumer Group details


Kafka Topics Generator

Will create topics on startup by using kafka console. kafka-topics.

References:

https://kafka.js.org/docs/getting-started

About

Basic structure and examples to start with kafka to your projects.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published