The Kleroterion’s Lot: A History of Process Fairness in System Selection
It’s 2:17 AM. The alert is screaming. Two redundant services, provisioned identically, are reporting a cascading failure. One node is clearly faltering under load, its logs a torrent of despair. The other appears pristine in its silence, sitting idle. The load balancer, entrusted with this critical choice, is making a decision every few milliseconds. But on what basis? Round-robin? Least connections? A custom heuristic we cooked up during a caffeine-fueled sprint? We seldom question the fundamental justice of the algorithm, the simple fairness of the mechanism that determines which machine bears the next burden.
This question of procedural fairness, of ensuring a kind of impartial distribution of duty, is ancient. Long before we had round-robin DNS or weighted resource pools, the citizens of classical Athens faced a similar problem. They needed to fill hundreds of public offices—jury duty, council positions—without corruption or favoritism. Their solution was a marvel of civic engineering and, to our eyes, a piece of mundane ops technology: the Kleroterion.
The Machinery of Impartiality
The Kleroterion was a stone slab, etched with columns of slots. Each eligible citizen would insert his personal identification token—a bronze ticket—into a slot. A funnel at the side of the stone would receive a mixture of black and white dice. An official would release the dice, one by one, down a tube. The pairing was brutally simple: a white die drawn for a row meant the citizens in that row were selected for service. A black die meant they sat this one out. The entire process was public, transparent, and reliant on a form of random chance that was, for its time, remarkably robust.
We can see the parallels. Their tokens are our service instances, registered in a pool. The dice are the load balancer’s selection logic. The goal is identical: to distribute work in a way that prevents any single entity from being unfairly burdened or, conversely, from languishing in idle privilege. The Athenians were deeply suspicious of systems that could be gamed by the powerful; they understood that the integrity of the entire state depended on the perceived and actual fairness of its basic processes.
When we configure our own modern Kleroteria, what principles do we encode? We obsess over efficiency, over raw throughput, and rightly so. But do we ever consider the ‘justice’ of our algorithms? A poorly tuned ‘least connections’ can inadvertently punish a healthy node that just finished a large job, making it appear idle and thus the prime target for the next massive request. A simple round-robin can blissfully send traffic to a node that’s beginning to hemorrhage memory, simply because it’s ‘its turn’. We lack the equivalent of the black die—a way to temporarily, but transparently, exempt a citizen from the lottery without removing it from the agora entirely.
The lesson from the Kleroterion isn’t about the virtue of randomness. It’s about the virtue of a transparent, deliberate, and auditable process. The Athenians didn’t trust a single archon to just point at people; they built a machine whose logic was visible to all. Our load balancers and schedulers are our black boxes. We trust their internal dice to be fair, but when they are not, the failure is often opaque. Perhaps the true operational wisdom is to occasionally channel the ancient archons: to design our selection systems not just for optimal performance, but for observable, debuggable, and fundamentally fair distribution. After all, the stability of our small digital polity depends on it.
Notes & further reading
A few pages I came back to while writing this:
- Surprise, AZ
- The Second Dawn: On the Ritual of the False Failure
- Tucson, AZ
- The Solstice Stone: On the Fixed Point in the Drift of Config
- Elk Grove, CA
- The Gardener's Graft: On the Quiet Art of Service Propagation
- Fullerton, CA
- Pasadena, CA
- Bridgeport, CT
- New Haven, CT
- Stamford, CT
- Washington, DC
- Cape Coral, FL