Skip to content

A microservices app with Async communication, optimistic concurrency and langauge agnostics

Notifications You must be signed in to change notification settings

TikZSZ/microservices-ticket-app

Repository files navigation

This is a microservice implementation of ticketing application

Note: The whole workflow is in TypeScript

This documentation includes

Requirements

Getting Started

For Development

git clone https://github.com/TikZSZ/microservices-ticket-app.git

cd ./microservices-ticket-app

# Make sure minikube is running to start minikube
minikube start

skaffold dev

To access the ingress-nginx we need to set minikube ip in hosts because its configured to have a hostName of ticketing.dev On Linux

sudo echo "$(minikube ip)  ticketing.dev" >> /etc/hosts

and now all routes are available to access.

For Production infra/k8s includes all configuration that can be used on cloud

API

Note: ticketing.dev is assumed to be set in /etc/hosts as minikube ip read getting started to set it up

Features

  • Async communication no inter service dependence and JWT as auth mechanism

  • Events driven architecture using Nats-Streaming with atleast once guarantee

  • Kubernetes workflow with skaffold to make development easy. All k8s configuration is in infra/k8s

  • MongoDB as database with database for each resource and optimistic concurrency control and Versioning for concurrency issues with some nitty-gritty features of mongoose

  • Redis and BullJS to deal with expiration job of orders

  • Isolated test cases for each service covering every aspect of service like database model, event flow and api routes

  • Good practices and highly decoupled and modular implementation of services

  • Common library for code-reuse

  • Language independent app flow for most part

  • Server-Side-Rendering with NextJS which also covers proxy-ing requests to backend (which is rather complex when using getInitialProps which is called on frontend and serverless functions depending upon state)

  • Summary of nitty-gritty details included per service basis as markdown in Summary Folder

Event-Flow

Mongoose

Pending Work

1 Payment service is not yet complete

2 ci/cd workflow has not been set on the repo

About

A microservices app with Async communication, optimistic concurrency and langauge agnostics

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published