atomic-waitgroup

Crates.ioatomic-waitgroup
lib.rsatomic-waitgroup
version0.1.3
sourcesrc
created_at2024-05-10 05:16:25.545972
updated_at2024-05-10 06:18:51.113164
descriptionA waitgroup implementation supports async with advanced features
homepage
repositoryhttps://github.com/frostyplanet/atomic-waitgroup-rs/
max_upload_size
id1235702
size17,636
Adam Ning (frostyplanet)

documentation

https://docs.rs/atomic-waitgroup

README

atomic-waitgroup

A waitgroup support async with advanced features, implemented with atomic operations to reduce locking in mind.

Features

  • wait_to() is supported to wait for a value larger than zero.

  • wait() & wait_to() can be canceled by tokio::time::timeout or futures::select!.

  • Assumes only one thread calls wait(). If multiple concurrent wait() is detected, will panic for this invalid usage.

  • done() can be called by multiple coroutines other than the one calls wait().

Commit count: 10

cargo fmt