Skip to content

Latest commit

 

History

History
20 lines (19 loc) · 904 Bytes

HOW_TO_RUN.md

File metadata and controls

20 lines (19 loc) · 904 Bytes

How to compile

run mvn clean package and it will create an executable jar file inside target directory

How to run

Start zookeeper and kafka

  1. Download apache kafka
  2. Start a ZooKeeper server. Kafka has a single node Zookeeper configuration built-in.
bin/zookeeper-server-start.sh config/zookeeper.properties
  1. Start kafka
bin/kafka-server-start.sh config/server.properties
  1. Create required topics (order-created, item-added, order-finalized)
bin/kafka-topics.sh --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic order-created-event
bin/kafka-topics.sh --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic order-item-added-event
bin/kafka-topics.sh --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic order-finalized-event