Shop platform — Kubernetes architecture

NGINX ingress fronting the shop namespace; Kafka decouples services from async workers; PostgreSQL & MongoDB data stores; Prometheus + Grafana observability.

Shop platform Kubernetes animated architecture diagram An NGINX ingress routes traffic to the users, catalog, cart and payments services in the shop namespace. A Kafka bus sits between the services and two async workers (email and analytics). Payments writes orders to PostgreSQL; catalog reads from MongoDB. Prometheus and Grafana run in an observability namespace. Animated cyan dots show a checkout request traveling from the ingress through cart and payments to PostgreSQL; orange dots show an async event from payments through Kafka to the email worker. Kubernetes cluster namespace: shop namespace: observability HTTPS :27017 :5432 publish consume scrape /metrics PromQL NGINX Ingress ingress-nginx · L7 Catalog products · REST Users accounts · REST Cart sessions · REST Payments checkout · gRPC Kafka · order & event topics MongoDB catalog Email Worker Kafka consumer Analytics Worker Kafka consumer PostgreSQL orders Prometheus metrics · scrape Grafana dashboards gateway service data store message bus observability request in flight async event

Checkout path

  • • Ingress → Cart → Payments → PostgreSQL
  • • Cyan dot = synchronous checkout request
  • • Orders persisted to PostgreSQL (:5432)

Async via Kafka

  • • Payments publishes order events to Kafka
  • • Email & analytics workers consume topics
  • • Dotted orange edges = async traffic

Data & observability

  • • PostgreSQL — orders system of record
  • • MongoDB — product catalog (:27017)
  • • Prometheus scrapes shop; Grafana queries PromQL