NOTE: a generalized write-up of a problem class I have worked on. Client names, data and internal details are omitted on purpose.
Context
A CRM platform needed data to stay consistent across several backend services, and new data had to be visible to users almost immediately.
Constraints
- High throughput, with sub-second ingestion.
- Services had to stay decoupled so teams could change them independently.
- The backend had to stay fast and easy to extend.
Decision
Build the integration around events. Services publish changes to Apache Kafka and RabbitMQ, and other services consume them instead of calling each other synchronously. Kafka carried the high-volume streams, and RabbitMQ handled routing and work distribution where that fit better.
Trade-offs
- Eventual consistency replaces simple request and response, so the design must say clearly what each consumer may assume.
- More infrastructure to operate and monitor.
- In return: independent scaling, resilience to slow consumers and room to add new consumers without touching producers.
Outcome
Real-time synchronisation across distributed services, and streaming pipelines with sub-second ingestion at scale, as the base of the platform’s core backend services.
What I would stress
Agree on event contracts and ordering guarantees early, and plan for replays and duplicates from the first day.