-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a mpmc channel #848
Comments
FWIW, a spmc channel would also be incredibly useful, and could probably be optimized in ways a mpmc can not. |
@jonhoo I started bulding a spmc lib for rust, though it needs optimizations, and I should probably dump the linked list idea.. oyashio/spmc lib |
Any updates on this? :-) |
https://github.com/jonhoo/bus could probably be adapted pretty easily to be spmc instead of sp-broadcast. Will probably simplify the code a fair amount in fact. |
Any update on getting this into Rust core? |
Would definitely be a useful feature. Is it to be integrated to rust 's sync library ? |
I believe crossbeam-channel has become the community preferred MPMC channel this year. |
@WiSaGaN thanks for the update. Closing this therefore. |
What about crossbeam-channel and tokio? Does it work with it or does it work with std threads only?... |
That's a question for crossbeam, not really a rust rfc |
@Centril I don't quite understand? How does this solve this issue? 🤔 |
Use crossbeam, using dependencies in Rust is easy and painless. So if something can be a dep instead of in std, putting it in a dep is preferred. |
Mh, should definitly work without dependencies... |
Hello from 2024. Since std's I assume this is mainly a naming churn problem, since we can't rename the Ultimately I'd love to have this in standard Rust, since it already exists in std anyway, but I'm curious to know what would need to be done to make this happen (besides the obvious 'make an RFC'), what kind of approach would be deemed possible and preferred by the libs team. |
@Centril @eddyb @jonhoo @Kixiron @WiSaGaN, apologies for the ping, but could we please consider reopening this issue? I believe that LunarLambda has made excellent points that warrant further comments at least. The closure of this RFC based on the existence of third-party libraries overlooks the benefits of having this capability integrated into the standard library, especially accessibility, consistent maintenance, and reduced dependency overhead. Given these points, I believe there is a strong case for revisiting this RFC. Having MPMC channels in the standard library would greatly enhance Rust's concurrency primitives and provide a more robust solution for concurrent programming. Thank you in advance for considering this request. |
@rmnilin issues in the RFC repo are mostly just a place for folks interested in an idea to talk about it. It being open or closed says nothing about the actual state of this. they're not used in any decision making process by the teams. pull requests are "actual" RFCs that are being actively developed. anyone interested in moving a proposal forward would write an RFC and open a pull request with the RFC itself. |
Note that the libs team is generally positive to adding this. Someone needs to do the work, however. |
Issue by mahkoh
Friday Dec 12, 2014 at 20:26 GMT
For earlier discussion, see rust-lang/rust#19783
This issue was labelled with: A-libs, A-threads in the Rust repository
The text was updated successfully, but these errors were encountered: