# Jitter: Making Things Better With Randomness

DevFeed: [Jitter: Making Things Better With Randomness](<https://devfeed.tech/articles/jitter-making-things-better-with-randomness-12472.md>)

Original publisher: [Read original article](<http://brooker.co.za/blog/2015/03/21/backoff.html>)

Author: Marc Brooker

Published: 2015-03-21T00:00:00Z

Content type: article

Language: en

Sources: [Marc Brooker's Blog](<https://devfeed.tech/sources/marc-brooker-s-blog.md>), [Marc Brooker's Blog](<https://devfeed.tech/sources/marc-brooker-s-blog-2.md>)

Topics: [distributed-systems](<https://devfeed.tech/topics/distributed-systems.md>), [quantization](<https://devfeed.tech/topics/quantization.md>), [networking](<https://devfeed.tech/topics/networking.md>), [Routing (disambiguation)](<https://devfeed.tech/topics/routing.md>), [systems](<https://devfeed.tech/topics/systems.md>)

Tags: [architecture](<https://devfeed.tech/tags/architecture.md>), [article](<https://devfeed.tech/tags/article.md>), [blog](<https://devfeed.tech/tags/blog.md>), [distributed-systems](<https://devfeed.tech/tags/distributed-systems.md>), [engineering](<https://devfeed.tech/tags/engineering.md>), [network](<https://devfeed.tech/tags/network.md>), [quantization](<https://devfeed.tech/tags/quantization.md>), [routing](<https://devfeed.tech/tags/routing.md>), [systems](<https://devfeed.tech/tags/systems.md>)

## AI overview

The article explains how randomness helps prevent systematic failures when a system lacks enough information to make the right choice. It connects jitter in distributed systems--where randomness reduces synchronization, contention, and wasted effort--with dither in quantization, where added noise reduces bias and prevents quantization errors from correlating with the original signal.

## Source excerpt

Jitter: Making Things Better With Randomness Jitter is a good thing. Two weeks ago, I wrote an article titled Exponential Backoff and Jitter for the AWS Architecture blog. It looks at OCC in particular, but the lessons are applicable to all distributed systems. The bottom line is that exponential backoff is good, but not sufficient to prevent both wasted time and wasted effort. Communication in distributed systems isn't the only place that adding randomness comes in handy. It's a remarkably wide-spread idea, that's found use across many areas of engineering. The basic pattern across all these fields is the same: randomness is a way to prevent systematically doing the wrong thing when you don't have enough information to do the right thing. One classic distributed systems example is in the paper The Synchronization of Periodic Routing Messages (thanks tptacek). Sally Floyd1 and Van Jacobson2 simulate synchronization emerging in previously unsynchronized systems communicating over a network. This leads to short-lived spikes in contention, and other correlated effects on the network. Their solution is to add randomness, which breaks the loop that creates synchronization. While the exact set of protocols and technologies they look at is very 1990s, the lessons are timeless. Closely related to these uses of jitter is dither, or adding noise to prevent artifacts when quantizing. Dither is most visible in images, where it can make a huge difference in quality3: Technically, dither is a way to remove correlation between quantization error and the signal being quantized. That sounds complex, but the underlying concept is extremely simple. Imagine a simple system where we're rounding a vector of reals to the nearest integer. If those reals are nicely distributed, it works well, but sometimes it works very poorly. If we start with [ 1.4, 1.4, 1.3, 1.4, 1.2, 1.4, 1.1, 1.0, 1.4 ] it rounds to [ 1, 1, 1, 1, 1, 1, 1, 1, 1 ] leaving the error [ 0.4, 0.4, 0.3, 0.4, 0.2, 0.4, 0.1, 0.