nconf-redis
A Redis store for nconf
Installation
Installing npm (node package manager)
$ curl http://npmjs.org/install.sh | sh
Installing nconf-redis
$ [sudo] npm install nconf$ [sudo] npm install nconf-redis
Motivation
tldr;?
: To break the nconf codebase into small modules that work together.
Usage
The store provided by nconf-redis
will persist all of your configuration settings to a Redis server. All calls to .get()
, .set()
, .clear()
, .reset()
are asynchronous taking an additional callback parameter.
The Redis engine also has an in-memory cache with a default TTL of one hour. To change this, just pass the ttl
option to .use()
.
var nconf = ;//// Requiring `nconf-redis` will extend the `nconf`// module.//;nconf;