Struct conhash::conhash::ConsistentHash [] [src]

pub struct ConsistentHash<N: Node> { /* fields omitted */ }

Consistent Hash

Methods

impl<N: Node> ConsistentHash<N>
[src]

Construct with default hash function (Md5)

Construct with customized hash function

Add a new node

Get a node by key. Return None if no valid node inside

Get a node by string key

Get a node by key. Return None if no valid node inside

Get a node by string key

Remove a node with all replicas (virtual nodes)

Number of nodes