main·5006ce4·1m ago

Go ecommerce platform

Asynchronous Systems Engineering

This section highlights the production-grade async work behind the Go ecommerce services: RabbitMQ for checkout saga coordination, Kafka for order domain events and replayable projections, and the operational guardrails that make message-driven systems debuggable after they leave the happy path.

The implementation is intentionally practical: Go, Kafka, and RabbitMQ are used where they solve concrete reliability problems in checkout, analytics, event sourcing, CQRS read models, and incident response.

RabbitMQ Checkout Saga

RabbitMQ coordinates the checkout workflow where services need explicit commands, replies, compensation, and operator recovery.

  • Checkout saga orchestration with command/reply queues across order, payment, inventory, and shipping boundaries.
  • Bounded retries with explicit DLQ routing so transient broker or service failures do not become infinite poison-message loops.
  • Replay/admin panel support for inspected DLQ messages, including operator-controlled recovery paths.
  • Publisher confirms, reconnect-aware publishing, graceful shutdown, and crash recovery around the RabbitMQ client lifecycle.

Kafka Event Streams

Kafka carries order facts as an append-only stream for event sourcing, CQRS projection, replay, and analytics.

  • Order domain events published as the durable event stream behind event sourcing and downstream projections.
  • CQRS projector paths that rebuild read models from replayable events instead of coupling UI reads to transactional writes.
  • Schema evolution, replay discipline, Kafka DLQ envelopes, consumer lag metrics, and streaming analytics over order activity.

Reliability Practices

Idempotency at async boundaries so duplicate deliveries and retries remain safe.

Retry classification that separates transient failures from validation and poison-message failures.

DLQs with enough envelope context to debug, alert, and replay without guessing.

Prometheus metrics for consumer lag, DLQ depth, saga progress, publish outcomes, and worker health.

Trace propagation through RabbitMQ headers and Kafka message headers for cross-service debugging.

Focused tests around retry behavior, replay paths, graceful shutdown, and crash recovery.

Related Demos