TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Concurrency Limits by Netflix

191 pointsby rshettyabout 7 years ago

10 comments

jsnellabout 7 years ago
The blog post announcing this might be a better read:<p><a href="https:&#x2F;&#x2F;medium.com&#x2F;@NetflixTechBlog&#x2F;performance-under-load-3e6fa9a60581" rel="nofollow">https:&#x2F;&#x2F;medium.com&#x2F;@NetflixTechBlog&#x2F;performance-under-load-3...</a><p>(And while reading that and thinking &quot;I swear I recently read something else talking about applying TCP congestion control to RPC queueing&quot;. And indeed I had: <a href="http:&#x2F;&#x2F;www.evanjones.ca&#x2F;prevent-server-overload.html" rel="nofollow">http:&#x2F;&#x2F;www.evanjones.ca&#x2F;prevent-server-overload.html</a>)
评论 #16675236 未加载
ramchipabout 7 years ago
This reminds me a lot of the sbroker library in Erlang:<p>&gt; SBroker is a framework to build fault tolerant task schedulers. It includes several built in schedulers based on TCP (and other network scheduling) algorithms.<p>&gt; [...] in an ideal situation a target queue time would be chosen that keeps the system feeling responsive and clients would give up at a rate such that in the long term clients spend up to the target time in the queue. This is sojourn (queue waiting) time active queue management. CoDel and PIE are two state of the art active queue management algorithms with a target sojourn time, so should use those with defaults that keep systems feeling responsive to a user.<p><a href="http:&#x2F;&#x2F;www.erlang-factory.com&#x2F;euc2017&#x2F;james-fish" rel="nofollow">http:&#x2F;&#x2F;www.erlang-factory.com&#x2F;euc2017&#x2F;james-fish</a><p><a href="https:&#x2F;&#x2F;github.com&#x2F;fishcakez&#x2F;sbroker" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;fishcakez&#x2F;sbroker</a>
lkrubnerabout 7 years ago
I like the sounds of this:<p>&quot;<i>Executor -- The BlockingAdaptiveExecutor adapts the size of an internal thread pool to match the concurrency limit based on measured latencies of Runnable commands and will block when the limit has been reached.</i>&quot;<p>I&#x27;m often surprised this kind of auto-scaling thread pool is not a more common thing in Java land.
评论 #16677084 未加载
baybal2about 7 years ago
PROTIP: Managing congestion control on application level is not a good business. A better idea is to leave it to the edge and CDN, while the app level uses computationally cheap optimistic algos since the com in between the app and your edge will go over your own high quality infrastructure.<p>This adds flexibility to allow for use of multiple algorithms in different load balancing regions (mobile as a lossy fabric is better to stay with conventional, desktop and server clients can use a some smarter throughput maximizing algo, and in countries with high percentages of connections being laggy DSLs, you can use something else )
评论 #16680107 未加载
time0utabout 7 years ago
This library looks very interesting. I&#x27;ve used a similar approach for pulling batches of items from a queue (e.g. discover the optimal batch size and inter-poll wait time). There are plenty of other places we could benefit from something like this. I can&#x27;t wait to try this out.<p>Netflix puts out some amazing Java libraries. I&#x27;ve had excellent results using Hystrix [0]. It has been an excellent addition to our systems.<p>[0] <a href="https:&#x2F;&#x2F;github.com&#x2F;Netflix&#x2F;Hystrix" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;Netflix&#x2F;Hystrix</a>
Anderkentabout 7 years ago
This is a pretty cool design if your requests to a given endpoint are supposed to all take about the same time. It&#x27;s not easy to see how you&#x27;d adjust it for things with more variance; perhaps rather than using the fastest seen mtt, you could look at your p99 over the last N minutes, and see if it&#x27;s been changing?
评论 #16680839 未加载
评论 #16678881 未加载
fwefabout 7 years ago
Would this work when connecting multiple threadpools (java executors)? Imagine I have a microservice where first threadpool downloads large files to disk (IO bound) and another threadpool that processes the downloaded data (CPU bound). Those two threadpools communicate with a bounded queue. Will using the concurrency-limit Executor allow me to get the best throughput in this scenario?
bvodabout 7 years ago
Can anyone explain how they decide which requests to reject? The blog post just mentions that excess RPS gets rejected, but couldn&#x27;t rejecting arbitrary requests cause other problems?
评论 #16680334 未加载
评论 #16678728 未加载
评论 #16678695 未加载
0354305about 7 years ago
I&#x27;m not grasping the concept; Do I use this in production to manage concurrency, or do I use this in &#x27;testing&#x27; to fine tune my system?
评论 #16677639 未加载
stephen123about 7 years ago
I would have thought reactive streams or back pressure would be the usual way to deal with this issue.<p>Is this better ?
评论 #16678516 未加载