You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Go to file
Taiki Endo 07c3e4d5b9
Minimize GITHUB_TOKEN permissions
6 days ago
.github Minimize GITHUB_TOKEN permissions 6 days ago
benches Add benchmarks for bounded queues (#24) 7 months ago
src feat: Add the try_iter method (#36) 4 weeks ago
tests Add alternate implementations of synchronization primitives (#27) 6 months ago
.gitignore Initial commit 3 years ago Release 2.1.0 3 months ago
Cargo.toml Release 2.1.0 3 months ago
LICENSE-APACHE Initial commit 3 years ago
LICENSE-MIT Initial commit 3 years ago Update license badge to match Cargo.toml 2 years ago


Build License Cargo Documentation

A concurrent multi-producer multi-consumer queue.

There are two kinds of queues:

  1. Bounded queue with limited capacity.
  2. Unbounded queue with unlimited capacity.

Queues also have the capability to get closed at any point. When closed, no more items can be pushed into the queue, although the remaining items can still be popped.

These features make it easy to build channels similar to std::sync::mpsc on top of this crate.


use concurrent_queue::ConcurrentQueue;

let q = ConcurrentQueue::unbounded();

assert_eq!(q.pop(), Ok(1));
assert_eq!(q.pop(), Ok(2));


Licensed under either of

at your option.


Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.