Event stream based Go microservice project using Nats JetStream, PostgresSQL & gRPC. Exhibit project to show case usage of cloud native ecosystem & tools.
- Golang 1.19+
 - Docker 20+ (compose extension)
 - Protoc compiler 3.8+
 
- 
Clone project & fetch go dependency
go mod download
 - 
Compile event protocol buffer file & gen gRPC code
make proto
 - 
Run the PSQL & Nats using docker
docker compose pull docker compose up -d
 - 
Run DB migrations create tables.
migrate -database ${POSTGRESQL_URL} -path migrations up - 
Run all the microservices in seprate shell
go run cmd/order-svc/main.go go run cmd/payment-svc/main.go
 - 
Run sample client event flow
go run cmd/client/main.go