Key-Value store with master-master replication support

90 views
Skip to first unread message

hellboy

unread,
Nov 4, 2014, 12:39:39 PM11/4/14
to nod...@googlegroups.com

I'm looking for file-based embedded store for Node.js with following features:

  1. Support for master-master replication that replicates real time changes so you can easily have a cluster of node.js processes (on several servers) where you can read or write to any of them. An appropriate conflict-resolution mechanism should be thought of.

  2. Support for both JSON and binary values

  3. Non-memory-based

Alan Hoffmeister

unread,
Nov 4, 2014, 12:57:15 PM11/4/14
to nodejs
I would take a look ad LevelUP and its plugin level-replicate and multilevel.

https://github.com/rvagg/node-levelup
https://github.com/juliangruber/multilevel
https://github.com/dominictarr/level-replicate

--
Alan Hoffmeister
https://twitter.com/alan_hoff
https://github.com/alanhoff
https://keybase.io/alanhoff
> --
> Job board: http://jobs.nodejs.org/
> New group rules:
> https://gist.github.com/othiym23/9886289#file-moderation-policy-md
> Old group rules:
> https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
> ---
> You received this message because you are subscribed to the Google Groups
> "nodejs" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to nodejs+un...@googlegroups.com.
> To post to this group, send email to nod...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/nodejs/dd38be82-f643-40f2-9644-1abfc0dfffd6%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Aria Stewart

unread,
Nov 4, 2014, 12:58:07 PM11/4/14
to nod...@googlegroups.com
On Tuesday, November 4, 2014 12:39:39 PM UTC-5, hellboy wrote:

I'm looking for file-based embedded store for Node.js with following features:

  1. Support for master-master replication that replicates real time changes so you can easily have a cluster of node.js processes (on several servers) where you can read or write to any of them. An appropriate conflict-resolution mechanism should be thought of.

What are your application's requirements for conflict-resolution? This isn't something that can be hidden from an application; it affects semantics of the system.

Aria 

Floby

unread,
Nov 5, 2014, 11:53:31 AM11/5/14
to nod...@googlegroups.com
ready-made solutions that I know of include CouchBase and CouchDB.

they are both pretty much the same in regard of your requirements.
  • blobs and docs are supported natively (but better done by CouchDB for JSON)
  • They both have master-master replication in real-time with default or custom conflict resolution mechanisms.
  • They both persist to disk even though CouchBase caches a lot more in-memory
Where they differ

  • CouchDB talks HTTP, CouchBase talks the memcached protocol
  • CouchDB uses map/reduce javascript functions to expose your data whereas CouchBase has N1QL (sql-like). This doesn't matter in any of them if you use this purely as key-value
  • CouchDB doesn't cache anything in memory
If you have a lot of writes, use CouchBase. There is a node driver developed by them.

Other solutions include etcd and zookeeper that I know less but also satisfy your use-case.
Reply all
Reply to author
Forward
0 new messages