Barabás Ákos

· 1 min read

Exactly Once Is Usually a Myth

Most distributed systems don't process messages exactly once. Designing software that behaves correctly anyway is the real challenge.

One of the most common misconceptions in distributed systems is that every message will be processed exactly once.

In reality, most queueing systems deliberately avoid making that promise. Messages may be delivered multiple times, processed after retries, or arrive later than expected. Network failures, worker crashes, and timeouts are all perfectly normal events.

Trying to eliminate every duplicate usually leads to unnecessary complexity.

Instead, the application itself should assume that duplicates are inevitable.

That often means designing idempotent operations. If processing the same message twice produces the same final state as processing it once, retries become far less dangerous. Workers can fail safely, queues can redeliver messages, and infrastructure becomes significantly more resilient.

This doesn’t remove every challenge. Ordering, partial failures, and long-running jobs still require careful thought.

But accepting that failures happen changes the design process completely.

Reliable systems aren’t built by assuming nothing will go wrong.

They’re built by assuming that eventually, something always will.