#channel #mpmc #select #golang #message

no-std crossbeam-channel

Multi-producer multi-consumer channels for message passing

28 releases

0.5.11 Jan 8, 2024
0.5.10 Dec 24, 2023
0.5.8 Apr 9, 2023
0.5.7 Feb 28, 2023
0.1.1 Nov 27, 2017

#19 in Concurrency

Download history 1149293/week @ 2023-11-07 1156059/week @ 2023-11-14 907117/week @ 2023-11-21 1088266/week @ 2023-11-28 1092974/week @ 2023-12-05 1164662/week @ 2023-12-12 937122/week @ 2023-12-19 602332/week @ 2023-12-26 1099663/week @ 2024-01-02 1185285/week @ 2024-01-09 1246915/week @ 2024-01-16 1268889/week @ 2024-01-23 1333247/week @ 2024-01-30 1359599/week @ 2024-02-06 1352203/week @ 2024-02-13 1165715/week @ 2024-02-20

5,430,816 downloads per month
Used in 6,036 crates (1,140 directly)



Crossbeam Channel

Build Status License Cargo Documentation Rust 1.60+ chat

This crate provides multi-producer multi-consumer channels for message passing. It is an alternative to std::sync::mpsc with more features and better performance.

Some highlights:

  • Senders and Receivers can be cloned and shared among threads.
  • Two main kinds of channels are bounded and unbounded.
  • Convenient extra channels like after, never, and tick.
  • The select! macro can block on multiple channel operations.
  • Select can select over a dynamically built list of channel operations.
  • Channels use locks very sparingly for maximum performance.


Add this to your Cargo.toml:

crossbeam-channel = "0.5"


Crossbeam Channel supports stable Rust releases going back at least six months, and every time the minimum supported Rust version is increased, a new minor version is released. Currently, the minimum supported Rust version is 1.60.


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.

Third party software

This product includes copies and modifications of software developed by third parties:

  • examples/matching.rs includes matching.go by Stefan Nilsson, licensed under Creative Commons Attribution 3.0 Unported License.

  • tests/mpsc.rs includes modifications of code from The Rust Programming Language, licensed under the MIT License and the Apache License, Version 2.0.

  • tests/golang.rs is based on code from The Go Programming Language, licensed under the 3-Clause BSD License.

See the source code files for more details.

Copies of third party licenses can be found in LICENSE-THIRD-PARTY.