Probabilistic Fair Ordering of Events
A growing class of applications depends on fair ordering, where events that occur earlier should be processed before later ones. Providing such guarantees is difficult in practice because clock synchronization is inherently imperfect: events generated at different clients within a short time window may carry timestamps that cannot be reliably ordered. Rather than attempting to eliminate synchronization error, we embrace it and establish a probabilistically fair sequencing process. Tommy is a sequencer that uses a statistical model of per-clock synchronization error to compare noisy timestamps probabilistically. Although this enables ordering of two events, the probabilistic comparator is intransitive, making global ordering non-trivial. We address this challenge by mapping the sequencing problem to a classical ranking problem from social choice theory, which offers principled mechanisms for reasoning with intransitive comparisons. Using this formulation, Tommy produces a partial order of events, achieving significantly better fairness than a Spanner TrueTime-based baseline approach.
💡 Research Summary
The paper tackles the problem of “fair ordering” of events in distributed systems, where an event that occurs earlier in real time should be processed before later events. Traditional sequencers impose an arbitrary total order based on arrival time (FIFO), which does not guarantee fairness, especially in latency‑sensitive domains such as financial exchanges, ad auctions, and online gaming. Achieving perfect fairness would require near‑perfect clock synchronization, which is provably impossible due to fundamental network delay uncertainty (Lundelius‑Lynch bound). Consequently, the authors propose a probabilistic notion of fairness: an earlier event should be ordered before a later one with high probability.
The core idea is to model each client’s clock offset as a probability distribution (typically a mixture of Gaussians) obtained from periodic synchronization messages (e.g., NTP, Chrony). When two events A and B arrive with noisy timestamps t_A and t_B, the sequencer computes the probability P(A precedes B) = P(t_A + ε_A < t_B + ε_B), where ε_A and ε_B are random variables drawn from the respective offset distributions. If this probability exceeds 0.5, the relation “likely happened before” (denoted p‑→) holds. However, unlike Lamport’s happened‑before relation, p‑→ is not transitive: it is possible to have P(A → B) > 0.5, P(B → C) > 0.5, and yet P(C → A) > 0.5, forming a Condorcet cycle.
To resolve the intransitivity, the authors map the sequencing problem to a classic ranking problem from social choice theory. Each event is treated as a candidate, and each pairwise p‑→ comparison is interpreted as a vote (the candidate with higher probability wins the pairwise contest). The resulting weighted tournament may contain cycles; the paper explores several well‑known voting rules—Copeland, Schulze, Ranked Pairs, etc.—to extract a consistent partial order that respects as many high‑probability pairwise preferences as possible. This transformation allows the system to produce a usable ordering even when a total order is mathematically impossible.
A further challenge is online sequencing: events arrive continuously, and future events may need to be placed before already‑seen events. Tommy, the proposed sequencer, addresses this by estimating a “potential timestamp range” for each incoming event based on the statistical model of all clients’ offsets. Before committing a rank, Tommy waits for any events whose timestamps could plausibly fall within that range, then batches them together and applies the social‑choice ranking algorithm to obtain a stable ordering. Events for which the model lacks confidence may receive the same rank, reflecting uncertainty rather than forcing an arbitrary decision.
The authors evaluate Tommy against a baseline that uses Google Spanner’s TrueTime abstraction. TrueTime represents each timestamp as an interval and orders events by sorting these intervals, effectively assuming a worst‑case bound on clock error. Experiments simulate high‑frequency workloads typical of exchanges and auctions, using realistic offset distributions derived from NTP/Chrony measurements. Results show that Tommy reduces ordering errors by 30‑70 % compared to the TrueTime baseline and, in several scenarios, matches the ideal fair order exactly. The improvement correlates with the accuracy of the offset distribution: better‑estimated models yield higher fairness. The online batching introduces modest latency but does not significantly affect overall throughput.
Limitations are acknowledged. Tommy relies on accurate offset distribution estimation; insufficient sampling can degrade performance. The current failure model is fail‑stop, and Byzantine clients that falsify offset information could corrupt the ranking. The paper suggests future work on robust trust mechanisms, adaptive voting rule selection, and extensions to Byzantine settings.
In summary, the paper introduces a novel framework that embraces clock synchronization error rather than fighting it. By converting probabilistic pairwise comparisons into a social‑choice ranking problem and by handling the online nature of event streams through careful batching, Tommy delivers a practical, probabilistically fair partial order. The approach bridges distributed systems and social choice theory, offering a general solution applicable to any domain where fair ordering matters but perfect synchronization is unattainable.
Comments & Academic Discussion
Loading comments...
Leave a Comment