@octoblu/redis-ns
This module enables you to create Redis namespaces.
Last updated 4 years ago by octoblu .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @octoblu/redis-ns 
SYNC missed versions from official npm registry.

NPM version

redis-ns

This module enables you to create Redis namespaces.

Example usage:

var redis = require('redis');
var RedisNS = require('redis-ns');

var redisClient = redis.createClient();

var client = new RedisNS('MyNameSpace', redisClient);
var client2 = new RedisNS('MyNameSpace2', redisClient);

client.set('bla', 'yadda1');
client.set('bla1', 'yadda1');

client2.set('bla', 'yadda2');
client2.set('bla2', 'yadda2');

The above will give you the following keys in Redis:

"MyNameSpace:bla"
"MyNameSpace:bla1"
"MyNameSpace2:bla"
"MyNameSpace2:bla2"

You can leave out the connection paramater, to create a new connection:

var client = new RedisNS('MyNameSpace');

This is an early BETA version

As soon as the module has shown it's worth and stability on a live system, it will be marked as version >= 1.0.0.

Until then: Feel free to play around with it, learn from it.

To install

npm install redis-ns

Build Status Code Climate Test Coverage npm version Gitter

Current Tags

  • 1.3.1                                ...           latest (4 years ago)

12 Versions

  • 1.3.1                                ...           4 years ago
  • 1.3.0                                ...           4 years ago
  • 1.2.2                                ...           4 years ago
  • 1.2.1                                ...           4 years ago
  • 1.2.0                                ...           4 years ago
  • 1.1.2                                ...           4 years ago
  • 1.1.1                                ...           4 years ago
  • 1.0.1                                ...           4 years ago
  • 1.0.0                                ...           4 years ago
  • 0.1.3                                ...           5 years ago
  • 0.1.2                                ...           5 years ago
  • 0.1.1                                ...           5 years ago

Copyright 2014 - 2016 © taobao.org |