bimap-rs
crossbeam
Our great sponsors
bimap-rs | crossbeam | |
---|---|---|
2 | 42 | |
124 | 6,832 | |
- | 1.8% | |
1.6 | 8.7 | |
7 months ago | 8 days ago | |
Rust | Rust | |
Apache License 2.0 | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
bimap-rs
-
BTreeMap but sorted by value?
Your requirements may be slightly different, but you could take a look at how e.g. bimap does it.
-
Announcing MultiIndexMap: A generic multi-index map inspired by cpp-boost's multi-index containers
`multi_index_map` is designed to allow storage and retrieval of data through multiple indexes, along the lines of in-memory relational database. This is useful in a few situations, notably when you want to implement structures like a bi-directional map (ie. searchable either for key or value), or sets with multiple iteration orders. There exist great crates for bi-directional maps already eg. [bimap-rs](https://github.com/billyrieger/bimap-rs/), however MultiIndexMap goes further and removes the distinction between key and value, such that as many keys as necessary can be added and searched for. Multiple iteration orders can be specificed using multiple `ordered_unique` keys, and iterating by these keys. Non-unique keys are also supported, so more than one element can be retrieved from a single lookup. This crate was inspired by [Boost's C++ Multi-Index Containers](https://www.boost.org/doc/libs/1\_80\_0/libs/multi\_index/doc/index.html), but completely redesigned for a more idiomatic Rust API. We've got to v0.4.0 now, and the main features have been fleshed out enough for me to feel comfortable announcing this. There is still lots to do, and I'm welcoming PRs from anyone who wishes to contribute. The [Future Work](https://github.com/lun3x/multi\_index\_map#future-work) section explains the general direction I am planning on going in.
crossbeam
-
Hyperbridge: Fast multi-producer, multi-consumer unbounded channel in Rust
Crossbeam isn't async[0]. It can multiplex with itself (via the `select!` macro), but not with anything else.
[0]: https://github.com/crossbeam-rs/crossbeam/issues/896
-
Where can I read about how to write a safe API for unsafe code?
Shooting from the hip, crossbeam might be a good candidate for understanding the thread safety aspects of Rust. I kind of feel like this is probably "too big" of a project if you're just learning, but I can't think of something smaller off the top of my head that would be suitable.
-
multi-producer multi-consumer channels for message passing python library
I am familiar with crossbeam channels, but now I need to work with python, and I was looking for a similar library.
-
I needed to write a simple multi-threaded message processing queue in C++ today. Makes me really appreciate how easy this is to do in Rust.
In the C++ example you create a naive mpsc queue using a std queue and a mutex, while in the rust example you use `std::sync::mpsc` which is now implemented internally using https://github.com/crossbeam-rs/crossbeam .
-
crossbeam VS scalable-concurrent-containers - a user suggested alternative
2 projects | 13 Apr 2023
-
Ergonomic Communication with a tokio::task::spawn
There are more in the ecosystem like in https://crates.io/crates/crossbeam
-
Rust Tips and Tricks #PartOne
The crossbeam crate offers a powerful alternative to standard channels with support for the Select operation, timeouts, and more.
-
How would one go about updating in-memory storage lock free, while other threads read?
From this project: https://github.com/crossbeam-rs/crossbeam
- This implementation is actually unsafe since we don't check if the index is in-bounds. But this is fine since this is only used internally.
What are some alternatives?
rpds - Rust persistent data structures
rayon - Rayon: A data parallelism library for Rust
hora - 🚀 efficient approximate nearest neighbor search algorithm collections library written in Rust 🦀 .
tokio - A runtime for writing reliable asynchronous applications with Rust. Provides I/O, networking, scheduling, timers, ...
heapless - Heapless, `static` friendly data structures
rust-threadpool - A very simple thread pool for parallel task execution
Rust - All Algorithms implemented in Rust
RxRust - The Reactive Extensions for the Rust Programming Language
multi_index_map - Simple and flexible multi-index containers.
coroutine-rs - Coroutine Library in Rust
Bus Writer - Single-reader, multi-writer & single-reader, multi-verifier; broadcasts reads to multiple writeable destinations in parallel
dashmap - Blazing fast concurrent HashMap for Rust.