Skip to content

saurookadook/node-kafka-mini-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

node-kafka-mini-app

A mini app in Node.js utilizing KafkaJS.

  • Coming Soon: Replicating Topics to tables in PostgreSQL via Postgres.js (or maybe a different library?)

Demo running producers and consumers

Installation

$ cd app
$ nvm use # if this fails, run `nvm install`
$ corepack enable
$ yarn install
$ cd ..
$ docker compose build all --no-cache

Runnin' the Containers

$ docker compose up all-kafka -d
# ^ check the logs in the containers to make sure that zookeeper, the brokers, the REST proxy, and the schema registry all started correctly

# TODO: still need to figure out how to add `healthcheck` and startup/retry conditions
#       so that **all** of the containers will start up in the correct dependency order

$ docker dompose up mini-app -d
# ^ check the logs in its container to make sure that the topic schema(s) get registered

Then run these in different tabs/windows:

Tab 1

$ docker compose up consumers -d && docker compose logs consumers --follow

Tab 2

$ docker compose up producers -d && docker compose logs producers --follow

Running the App

🚧 WIP 🚧

References

About

A small NodeJS app that creates, writes to, and reads from topics in Kafka.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published