Structured Concurrency Feedback

Alan Bateman alan.bateman at oracle.com
Tue Oct 21 10:06:47 UTC 2025



On 21/10/2025 08:40, Filip Egeric wrote:
> Hello,
>
> I would like to follow up on this one, because I also found myself 
> creating a wrapper similar to this one, but for a different reason.
> Specifically, when I want to limit concurrency in order to not exceed 
> a rate limit somewhere.

Have you tried using a ThreadFactory factory instead? A custom 
ThreadFactory can be used to wrap all tasks so you get the 
acquire/release to limit concurrency.

-Alan


More information about the loom-dev mailing list