fibre is a full suite of high performance, memory efficient, multimode sync/async, cancel-safe and strictly ordered channels for Rust.
Instead of one general-purpose queue it ships a separate channel for each producer and consumer pattern: spsc for one-to-one, mpsc for many-to-one, spmc for broadcast, spmc::topic for publish-subscribe, mpmc for many-to-many and oneshot for a single reply. Each one is built for its pattern, so a one-to-one pipe doesn't pay for the locking a many-to-many queue needs.
Depending on the type, a channel can be bounded, unbounded or a zero-capacity rendezvous. The handles share one set of method names with the same meaning on every type: send, try_send, recv, try_recv, recv_timeout and close. The four core channels also have a batch API that moves many items in one call. Async receivers implement futures::Stream, so you can drive them with StreamExt combinators.
Sync and async code can share a channel. Every sender and receiver on spsc, mpsc, spmc and mpmc has a zero-cost to_sync() or to_async(), so a producer on a plain OS thread can feed a consumer running in a Tokio task.
Shutdown works the same way everywhere. Drop every sender and the receivers drain what is already buffered before they see Disconnected, so closing a pipeline in order doesn't lose work.
use StreamExt;
let = ;
spawn
;
while let Some = rx.next.await
