Oasis Retry Ladder
The water beacon is busy. Build a calm retry program that waits longer after each failure, spreads caravans apart, and stops the moment the message succeeds.
π§ Before we start
In the Firefly Hash Ring, one steady rule prevented routing chaos when a tree changed. Today, exponential backoff prevents retry chaos: after each failure, a program waits longer before trying again.
Arrange the calm retry program
Tap four visual instruction blocks in the safe order. A failed request must wait before it returns.
Climb the waiting ladder
The first three requests fail. Choose the next wait each time: one beat, then two, then four. The fourth request succeeds.
Stop two caravans colliding
Both caravans started together and chose the same waits. Add a tiny random wiggle so their next requests reach different beats.
Debug the runaway caravan
The beacon answered successfully, but the buggy program waits and sends another request anyway. Repair the stopping rule.
π What you learned
- A retry asks again after a temporary failure.
- Exponential backoff makes each pause longer than the one before.
- Longer waits give a busy service time to recover.
- Jitter adds a tiny random offset so many workers do not retry together.
- A success is a stopping condition: the retry loop must end.
- Backoff, jitter, and stopping rules keep shared systems calm.