Skip to content

Latest commit

 

History

History
33 lines (21 loc) · 1.67 KB

File metadata and controls

33 lines (21 loc) · 1.67 KB

Spring Boot, Ports & Adapters Architecture with Kafka Producer-Consumer, Schema Registry & AVRO

Spring Boot, Ports & Adapters Architecture with Kafka Producer-Consumer, Schema Registry & AVRO

Description

Refer to this DZone article here: https://dzone.com/articles/ports-and-adapters-architecture-with-kafka-avro-and-spring-boot

Docker

To bring up the entire Kafka infrastructure, including Zookeeper, Kafka-Broker & Kafka Schema Registry, in Docker environment, cd to the directory containing docker-compose.yml and then execute the command:

docker-compose up

Once the Kafka infrastructure is up, we can list the topics with this command:

docker run -it --rm --name kafka_client_consumer --network kafka_network confluentinc/cp-kafka:7.0.1 /bin/kafka-topics --bootstrap-server kafka_server:29092 --list

Once we are done with the Kafka infrstructure, we can bring the entire environment down ny executing the following command:

docker-compose down

With this setup in Docker, we do NOT need any Kafka infrastructure, including Kafka Client, installed locally on our machine.