Concurrent multi-producer multi-consumer queue
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
dependabot[bot] f41c20d8b9
Some checks failed
ci.yml / Update criterion requirement from 0.7 to 0.8 (#80) (push) Failing after 0s
Update criterion requirement from 0.7 to 0.8 (#80)
Updates the requirements on [criterion](https://github.com/criterion-rs/criterion.rs) to permit the latest version.
- [Release notes](https://github.com/criterion-rs/criterion.rs/releases)
- [Changelog](https://github.com/criterion-rs/criterion.rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/criterion-rs/criterion.rs/compare/criterion-plot-v0.7.0...criterion-v0.8.0)

---
updated-dependencies:
- dependency-name: criterion
  dependency-version: 0.8.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-02 23:35:56 +09:00
.github ci: Use reusable workflows for fmt and security_audit 2025-01-20 01:42:01 +09:00
benches Update criterion requirement from 0.5 to 0.6 (#78) 2025-07-26 15:40:35 +09:00
src Fix typo 2025-01-20 01:42:01 +09:00
tests tests: Add more tests for force_push 2024-04-22 19:01:51 -07:00
.gitignore Initial commit 2020-05-27 21:31:05 +02:00
Cargo.toml Update criterion requirement from 0.7 to 0.8 (#80) 2025-12-02 23:35:56 +09:00
CHANGELOG.md v2.5.0 2024-04-26 07:25:42 -07:00
LICENSE-APACHE Initial commit 2020-05-27 21:31:05 +02:00
LICENSE-MIT Initial commit 2020-05-27 21:31:05 +02:00
README.md Fix workflow's badge (#76) 2025-07-26 15:44:50 +09:00

concurrent-queue

CI 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.

Examples

use concurrent_queue::ConcurrentQueue;

let q = ConcurrentQueue::unbounded();
q.push(1).unwrap();
q.push(2).unwrap();

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

License

Licensed under either of

at your option.

Contribution

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.