nosql - Equivalent of an ORM for a distributed key/value store? -


i'm in process of evaluating how implement using distributed key/value store end. i'd have layer on top of key/value supporting object model similar i'd object-relational mapper.

can point me @ examples of other people doing this? i'm looking design ideas, though if run across enough may use instead of writing own. i'm going wind implementing mine in perl on top of riak, decisions not final.

we have used riak similar, using ruby client ripple exposes acivemodel interface. however, have advise against (as others have). using heavy orm on top of key/value store lose it's main advantage, speed.

we moving towards skipping ripple , talking directly riak lot of speed conscious things (we moving erlang , using pbc rather http interface, that's story :d), here how it:

  • in our objects store json document, in ripple compatible format. although have requirement of still use ripple things, if again without ripple still use format.

  • use riak links join objects together, don't store foreign keys in document itself. advised there limit number of links can store on object, don't go crazy them (e.g. storing link each comment on user object).

  • ripple (and riak) doesn't support indexes, had roll our own solution. example store user object randomly generated key, 'fen2nf4j9fecd' in 'users' bucket. store object key 'tom' in 'users_index_by_username' bucket riak link object in 'users' bucket. way can find user has username 'tom'.

you may want using key filtering. haven't played yet, have seen performance figures quite good. need careful riak not list keys of bucket due way implemented, riak searches keys, not bucket's keys.

riak quite beast, once head around love it. make's replication effortless, , 'just work'.


Comments

Popular posts from this blog

php - What is the difference between $_SERVER['PATH_INFO'] and $_SERVER['ORIG_PATH_INFO']? -

fortran - Function return type mismatch -

queue - mq_receive: message too long -