A lightweight, local dictionary service
Using npm:
$ npm i -g rades-rache
//default instance
let rache = require('rades-rache').default
//or you can create a new instance
//const {Rache} = require('rades-rache')
//let rache = new Rache()
async () => {
await rache.init()
//String
await rache.set("mario", 1)
let v = await rache.get("mario") //"1"
//List
await rache.lpush("list", 1, 2, 3)
v = await rache.lrange("list", 0, -1) //"3", "2", "1"
//Hash
await rache.hmset("hash", "k", 1, "q", 2)
v = await rache.hgetall("hash") //"k", "1", "q", "2"
await rache.close()
}
rades-rache
is just use for quickly server development. It's just like redis but without any other dependency.rades-rache
is worked well withrades
solution. Learn Morerades-rache
is not a stand-alone service. No network, no configure, just require it and use.
- string
- append
- decr
- decrby
- get
- getrange
- getset
- incr
- incrby
- incrbyfloat
- mget
- mset
- msetnx
- set
- setrange
- strlen
- hash
- hdel
- hexists
- hget
- hgetall
- hincrby
- hincrbyfloat
- hkeys
- hlen
- hmget
- hmset
- hset
- hsetnx
- hstrlen
- hvals
- list
- lindex
- linsert
- llen
- lpop
- lpush
- lpushx
- lrange
- lrem
- lset
- ltrim
- rpop
- rpoplpush
- rpush
- rpushx
- lifetime
- expire
- expireat
- persist
- pexipre
- pexpireat
- pttl
- ttl
- db
- exists
- flushall
- type