#join #limited #future #download #concurrency #server #zero-dependency

limited-join

A zero-dependency crate providing a join future with limited concurrency

1 unstable release

0.1.0 Jul 20, 2022

#1121 in Asynchronous

Download history 48/week @ 2023-12-08 133/week @ 2023-12-15 49/week @ 2023-12-22 69/week @ 2023-12-29 128/week @ 2024-01-05 38/week @ 2024-01-12 131/week @ 2024-01-19 99/week @ 2024-01-26 78/week @ 2024-02-02 81/week @ 2024-02-09 95/week @ 2024-02-16 98/week @ 2024-02-23 237/week @ 2024-03-01 257/week @ 2024-03-08 137/week @ 2024-03-15 98/week @ 2024-03-22

744 downloads per month

MIT license

10KB
149 lines

limited-join

Docs.rs Crates.io Unlicense

A zero-dependency crate providing a join future with limited concurrency.

Example

// Pretend we have a ton of files we want to download, but don't want to overwhelm the server.
let futures = files_to_download.into_iter().map(download::download_file);

// Let's limit the number of concurrent downloads to 4, and wait for all the files to download.
limited_join::join(futures, 4).await;

No runtime deps