SSDB is key-value(zset, hash, list) storage server, with Google LevelDB as storage engine, its goal is to replace Redis when encounter large sum of data that won’t fits the server’s memory.
https://github.com/ideawu/ssdb
SSDB Docs: http://ssdb.io/docs/
SSDB’s main features:
- Uses Google LevelDB as storage engine
- Master-slave replication, recover from break point after network failure
- Online backup through network
- Very suitable for storing collection data
- Uses small RAM
PHP API
<?php require_once('SSDB.php'); $ssdb = new SimpleSSDB('127.0.0.1', 8888); $resp = $ssdb->set('key', '123'); $resp = $ssdb->get('key'); echo $resp; // output: 123
PHP API Docs: http://ssdb.io/docs/php/
SSDB vs Redis
I want to use SSDB but I don’t speak read/write chinese. Most of the companies using it seem to be chinese? I am concerned that this will make it difficult to find answers because most of the discourse is in a language that I don’t understand.
Is there a big english community around ssdb that I havent found yet? Reply
For KV engine, I am looking for an enhanced levelDB lib that supports set and hash, but I do not need those fancy stuff like socket / server / master-slave etc. A pure lib like levelDB is more than enough for my scenario. Is it possible for me to use SSDB in such manner? (or with affordable changes). please advise, thank you. Reply
I was a little confused by http://ssdb.io/docs/redis-to-ssdb.html – does this mean that redis clients sending a zScore (for example) would not work since the SSDB command seems to be called zget? If not, why give it different names – does it do something different?
Its confusing to have something that is so close to redis, claims to be a redis replacement, but then uses different function calls for the same thing (even if they are really aliased.)
Can you explain more of why you gave the same redis commands different names? Reply
Thanks for the explanation – I understand better now. I’m not sure if I agree because is it’s not the same thing. The relationship between a key and value with a key-value isn’t the same relationship as a member and score in a zset (at least in redis, maybe in ssdb it’s the same), though superficially they look the same. The data structures and use cases are different (eg, in zset the score can only be numbers)
I guess what seems odd is that you’re trying to make a redis replacement and then renaming the functions. If it did something else, I can hear. But to change it because you think zget makes more sense, makes less sense and makes it more confusing. Is it at least aliased so that zScore will work?
The same is true of the q* naming – read – http://stackoverflow.com/questions/3940839/list-vs-queue-vs-set-of-collections-in-java – for a reference – a queue is made to only access the ends – a list can access the ends or ranges in the middle. http://ssdb.io/docs/commands/qslice.html makes no sense if it’s a queue. Reply
Does SSDB persist data from memory to disk as well?
I think it’s not quite clear how it’s working in common, generally the way I can think of: stores the data in memory, persists to disk as well as ability to use replica nodes?
Thanks. Reply
Let me introduce you this module for SSDB and vert.
https://github.com/jpv/ssdb-mod
Thank you for the great job. Reply