High availability: High availability is achieved through multiple readable and writable backups; Final consistency: fast and complete data synchronization is achieved through hash tree (data may be inconsistent in a short time); Easy expansion: capacity expansion can be carried out without interrupting services; High performance: asynchronous IO and high performance Key Value data Tokyo Cabinet ; Configurable availability and consistency: configured through N, W, R; Simple protocol: Memcached Compatible protocol, a large number of available clients.
from dbclient import Beansdb # three beansdb nodes on localhost BEANSDBCFG = { "localhost:7901": range(16), "localhost:7902": range(16), "localhost:7903": range(16), } db = Beansdb(BEANSDBCFG, 16) db.set('hello', 'world') db.get('hello') db.delete('hello')
$ beansdb -d $ memstorm -s localhost:7900 -n 1000000 -k 10 -l 100 ---- Num of Records : 1000000 Non-Blocking IO : 0 TCP No-Delay : 0 Successful [SET] : 1000000 Failed [SET] : 0 Total Time [SET] : 51.77594s Average Time [SET] : 0.00005s Successful [GET] : 1000000 Failed [GET] : 0 Total Time [GET] : 40.93667s Average Time [GET] : 0.00004s