8 releases
0.1.8 | Nov 2, 2021 |
---|---|
0.1.6 | Aug 15, 2019 |
0.1.5 | Nov 22, 2018 |
0.1.3 | Jan 24, 2017 |
0.1.2 | Nov 29, 2016 |
#863 in Algorithms
1,563 downloads per month
Used in 5 crates
(3 directly)
7KB
95 lines
Jump Consistent Hash
A fast, minimal memory, consistent hash algorithm.
Example
Cargo dependencies:
[dependencies]
jumphash = "~0"
Rust code:
extern crate jumphash;
let jh = jumphash::JumpHasher::new();
let slot_count = 100;
let slot_for_key = jh.slot(&"key", slot_count);
lib.rs
:
An implementation of the Jump Consistent Hash Algorithm.
Example
extern crate jumphash;
let jh = jumphash::JumpHasher::new();
let slot_count = 100;
let slot_for_key = jh.slot(&"key", slot_count);
Dependencies
~365KB