async-selector-0.2.0 has been yanked.
async-selector
Fast and flexible Future/Stream/task selector.
Designed for optimal performance when polling a large number of tasks (see example).
Allows for:
- Polling multiple tasks concurrently on the same thread
- Safely injecting shared state into polling logic
- Accessing and removing the tasks by automatically assigned unique ids
Examples
Simply flatten a set of streams:
let mut selector = default;
.for_each;
let collected = selector..await;
assert_eq!;
Use as a map of streams:
let mut selector = default;
let txs =
.map
.;
for in txs
More examples live here.