7 Comments
May 15·edited May 15

May I get a more concrete example of how the Thundering Herds issue could happens? In what circumstance will a value cache miss trigger multiple requests to update it?

Expand full comment
May 16·edited May 16

If there are 1000 clients looking for the same value at the same time and has a cache miss, then all these 1000 requests would hit the database, increasing the traffic. With the leasing, the memcache server sees, that this particular key is being fetched by a client, so they ask the other clients to retry the request after a set time, instead of hitting the database. Which would prevent the thundering herd problem.

Expand full comment

Thank you for the great example! It is clear to me now!

Expand full comment

Superb explanation and lots of valuable insights. Thank you sharing 😍

Expand full comment

This was a great read. Thank you!

Expand full comment

Thank you sharing. Very fun to read and easy to understand. Would you mind if i translate this article to korean? I want to share this article to my korean teammates.

Expand full comment

What a great read. Thanks for the through breakdown.

Expand full comment