mpmc-queue 0.1.0

A bounded multi-producer multi-consumer queue using Mutex + Condvar
Documentation
  • Coverage
  • 0%
    0 out of 9 items documented0 out of 7 items with examples
  • Size
  • Source code size: 8.58 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.4 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 57s Average build duration of successful builds.
  • all releases: 57s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • amitpatel-wstf/mpmc-queue
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • amitpatel-wstf

MPMC Queue

A bounded multi-producer multi-consumer queue implemented in Rust using Mutex + Condvar.

Features

  • Blocking push/pop
  • Non-blocking try_push/try_pop
  • Thread-safe

Example

use mpmc_queue::queue::{BoundedQueue, MpmcQueue};

let q = MpmcQueue::new(2);
q.push(1);
println!("{}", q.pop());

Usage

# Run example
cargo run

# Run tests
cargo test

# Run benchmark
cargo run --bin bench --release