Hacker news

  • Top
  • New
  • Past
  • Ask
  • Show
  • Jobs

How Uber Protects Against Retry Storms (https://www.uber.com)

117 points by iscmt 2 days ago | 49 comments | View on ycombinator

prologic 2 days ago |

So, effectively if A → B → C → D and D is failing, C may retry D, but B and A are discouraged from retrying the whole chain.

This is quite slever. I also really like the concept of an "Error Budget", inspired by SRE and SLO(s) no doubt :)

nirui 1 day ago |

I think the example is still too generic.

First thing is, if your service has 7 call layers, maybe it's just too deep.

Second thing is, I found that retry strategy works the best if you define it based on what the nodes are actually doing (instead of treating them as generic nodes). For example, if node D is a database failing a transaction, you may just configure it to retry the transaction instead of doing an application-initialized request resubmit, because the database probably knows better about why the transaction has failed than the application connected to it.

Third thing is, retry is worth it only when progress has been and/or can still be made. If the resources is no longer available forever, then there's no point of retrying.

Scoundreller 2 days ago |

Meanwhile Google keeps giving me “please wait, do not reload page” walls, so I ctrl-r as rapidly as possible. Or is that the human test and response?

maxchisto 2 days ago |

I'm suspicious of load shedding not mentioned in the article. Combine that with exp backoff in the caller and you got yourself a pretty robust starting point

aftbit 2 days ago |

I'd be interested to hear other strategies in this space. I've done the naive thing of allowing retries everywhere, and gotten into retry storms. When I was next presented with the problem, I tried the other naive thing of only allowing retries from the very top level service, which led me to redoing absolutely tons of work for each failure. What's a nice middle path that doesn't add too much complexity?

penguin_booze 2 days ago |

It's not related to the article content, but I can't help but notice the "diversity" in authorship grades: a senior staff, a (regular) senior, and a principal. I suppose grades are a key mechanism by which corporates keep their hamster wheels running.

I'm thankful that, at my $WORK, we're all software engineers by title, from the lowly interns to the CTO. Still, everybody knows who's who and whom to talk to, depending on the gravity of the issue.

whatever1 2 days ago |

Easy. Take a larger cut from the driver for each retry.

siscia 2 days ago |

It seems VERY cooperative.

If you can afford that, with all the coordination costs that it comes from it, good.

An alternative is just to let the downstream service own the retry logic. Too many requests? Just error out as soon as possible.

Each team manages its budget and each other team adapts.

UltraSane 2 days ago |

This feels like trying to reinvent Fibre Channel's flow control mechanism.

zyngaro 1 day ago |

TLDR: retry only if the error is owned by the immediate next hop (assuming you can determine ownership). The engineering is sound, but the article misses a important connection to queueing theory which shows in much simpler terms how retries can increase the instability of a system already under stress.

whoevercares 2 days ago |

Token bucket is all you need

cynicalsecurity 2 days ago |

> Deepanshu Mehndiratta, Alok Srivastava, Vibhor Dhingra, Ankit Srivastava

It's not AI that is going to replace you, folks. Btw is it a coincide or has Uber become a family business now?

iwontberude 2 days ago |

[dead]