flurry
flurry copied to clipboard
A port of Java's ConcurrentHashMap to Rust
Maybe we could run [`cargo audit`](https://crates.io/crates/cargo-audit) on the CI for security audits. Just run it on my machine: ``` $ cargo audit Fetching advisory database from `https://github.com/RustSec/advisory-db.git` Loaded 73 security...
We just merged #43, which gives us benchmarks! Currently we have benches against [`dashmap`](https://github.com/xacrimon/dashmap/tree/master/benches) and [`hashbrown`](https://github.com/rust-lang/hashbrown/tree/master/benches). First runs of the benchmarks seem to indicate that retrieving values from the map...
[The Java code](https://github.com/jonhoo/flurry/blob/d3dae0465b37b7f12c4f0d58a16f36fb1d8c1596/jsr166/src/ConcurrentHashMap.java#L400-L411) uses the `LongAdder` and`CounterCell` types in `add_count` to both improve the scalability of tracking the number of elements, and to intelligently sense when a resize should happen....
# Abstract As I see it we have no built in support for mutating data in a race-free way, this "RFC" will look into how we could implement this. #...
There are many Java tests that we do not yet have in the Rust version. You can find most of them in [this file](https://github.com/jonhoo/flurry/blob/master/jsr166/test/ConcurrentHashMapTest.java) from JSR166 and in [this folder](https://hg.openjdk.java.net/jdk/jdk13/file/tip/test/jdk/java/util/concurrent/ConcurrentHashMap)...
It is easy to write simple benchmarks for concurrent hash tables. But when these data-structures hit real world data is when we learn how they truly perform. There has been...
Add [`computeIfAbsent`], [`computeIfPresent`], [`compute`] I have a suspicion that `ReservationNode` could also be used to implement an [`Entry`-API] like the one on `std::collections::HashMap`, so that may be worth looking into....
We should implement [`rayon` parallel iterators]. The notes and code in [`iter/plumbing`] may be helpful, and the [`hashbrown` implementation](https://github.com/rust-lang/hashbrown/tree/b8c34c96924ccfbe79a09d0ffc01d0744a42afcb/src/external_trait_impls/rayon) too. [`rayon` parallel iterators]: https://docs.rs/rayon/1/rayon/iter/index.html [`iter/plumbing`]: https://github.com/rayon-rs/rayon/tree/master/src/iter/plumbing