prodNotification DBRate-limit storeEmail providerThird-party integratorPush providerSMS providerCustomerclusterdataedgeservicesevent_busCONTAINER · Apache Kafka Domain events between servicesorder_dbCONTAINER · PostgreSQL Orders and order status historyredisCONTAINER · Redis Active sessionsuser_dbCONTAINER · PostgreSQL User accounts and profilesgatewayCONTAINER · Kong Gateway, Lua plugins Routes, authenticates and rate-limits requestsnotifierCONTAINER · Node.js, gRPC Sends notifications and manages preferencesorder_apiCONTAINER · Go, gRPC Order creation, status, cancellation and historyuser_apiCONTAINER · Go, gRPC Registration, login, profiles and tokens Consumes order.* and user.createdKafkaConsumes user.deleted to anonymize ordersKafka/api/notifications/*gRPC/api/orders/*gRPC/api/users/*gRPCReads and increments countersReads templates and preferencesSends emailHTTPSSends push notificationsHTTPSSends SMSHTTPSPublishes order.created, order.paid, order.shipped, order.deliveredKafkaSends immediate notificationsgRPCReads and writes ordersSQLLooks up the ordering usergRPCPublishes user.created, user.updated, user.deletedKafkaCaches sessionsReads and writes usersSQLPublic API callsHTTPSWeb and mobile app requestsHTTPS
prod · SVG · D2 source

Long dashes: asynchronous. Short dashes: leaves this view.

In this view

  • event_bus container Apache Kafka

    Domain events between services

  • gateway container Kong Gateway, Lua plugins

    Routes, authenticates and rate-limits requests

  • notifier container Node.js, gRPC

    Sends notifications and manages preferences

  • order_api container Go, gRPC

    Order creation, status, cancellation and history

  • order_db container PostgreSQL

    Orders and order status history

  • redis container Redis

    Active sessions

  • user_api container Go, gRPC

    Registration, login, profiles and tokens

  • user_db container PostgreSQL

    User accounts and profiles

Leaves this view

  • gateway → Rate-limit store (outside): Reads and increments counters
  • notifier → Notification DB (outside): Reads templates and preferences
  • notifier → Email provider (outside): Sends email
  • notifier → Push provider (outside): Sends push notifications
  • notifier → SMS provider (outside): Sends SMS
  • Third-party integrator (outside) → gateway: Public API calls
  • Customer (outside) → gateway: Web and mobile app requests