Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

level-cluster

eugeneware8BSD-3-Clause0.0.7

Use consistent-hashing with hash-rings to distribute reads and writes across multiple multilevel nodes.

level, levelup, leveldb, cluster, hash, clustering, availability, high-availability, nosql, datqbase, node-hashring, hashing, consistent, multilevel

readme

level-cluster

Use consistent-hashing with hash-rings to distribute reads and writes across multiple multilevel nodes.

build status

NB: Work in progress. Not currently suitable for production.

Installation

This module is installed via npm:

$ npm install level-cluster

Example Usage

Assuming some multilevel servers listening on ['127.0.0.1:3000', '127.0.0.1:3001', '127.0.0.1:3002']:

var servers = ['127.0.0.1:3000', '127.0.0.1:3001', '127.0.0.1:3002'];
var db = new LevelCluster(servers);
db.put(...); // will consistently hash the write to a server based on the key
db.get(...); // will retrieve the right data from the right server
db.createReadStream(); // will stream the data from the different servers and create a unified stream