Distributed Systems

Messaging, consistency, resilience and scaling across services.
03
Jan
Street photograph by Stalin Pereira

Implementing W3C Trace Context across Distributed Services

Why you cannot debug without a Trace ID spanning all services
2 min read
28
Dec
Street photograph by Stalin Pereira

Implementing Exponential Backoff to Prevent Thundering Herds

Immediate retries turn a brief blip into a self-inflicted outage. How exponential backoff with full jitter works, a production-ready retry helper in TypeScript, Envoy and gRPC configs, and where retries should and should not live.
8 min read
26
Dec
Street photograph by Stalin Pereira

Implementing Circuit Breakers with Resilience4j/Polly

Implementing patterns to stop cascading failures in services
1 min read
24
Dec
Street photograph by Stalin Pereira

Handling Duplicate Messages in Kafka Consumers

Kafka delivers at least once, and its exactly-once features stop at the edge of Kafka. Where duplicates come from, and how to build idempotent consumers with an inbox table, sane offset commits, and dead letter topics for poison pills.
8 min read
23
Dec
Street photograph by Stalin Pereira

Explaining Eventual Consistency to Non-Technical Stakeholders

Explaining to stakeholders why data isn't instantly consistent
1 min read
17
Dec
Street photograph by Stalin Pereira

Decoupling Microservices: Moving from REST to Events

The trade-off between coupling (HTTP) and latency (Events)
1 min read
02
Dec
Street photograph by Stalin Pereira

The Distributed Nightmare of Auto-Numbers

Why auto-increment fails when you try to shard a database or merge data from multiple regions
1 min read
28
Nov
Street photograph by Stalin Pereira

Kafka vs. NATS: Why Your Team Is Probably Better Off With the Underdog

Challenging the default enterprise choice of Kafka by arguing that for most modern, real-time applications, NATS provides a simpler, more performant, and cost-effective solution without the operational overhead.
1 min read