A Sails/Waterline adapter for Redis. May be used in a Sails app or anything using Waterline for the ORM.
This waterline-redis
stores indexes of unique attributes for relatively fast lookups. Collections with multiple unique constraints will create multiple index sets.
Install is through NPM.
$ npm install sails-ioredis
Set your connection adapter on sails / waterline to 'sails-ioredis'
The following connection configuration is available:
// default values inline
config: {
port: 6379,
host: 'localhost',
password: null,
db: null,
// SENTINEL CONFIG:
// sentinels: [{ host: 'host1', port: 26379 },{ host: 'host2', port: 26379 }, ...] // array of sentinel servers
// name: 'master', // name of the sentinel master
// USING WITH CLUSTER:
hosts: [{ host: 'host1', port: 26379 },{ host: 'host2', port: 26379 }, ...],
// ^--- if you specify an array of hosts the adapter will use ioredis cluster instead
};
See options at: https://github.com/luin/ioredis
See FAQ.md
.
See CONTRIBUTING.md
.
See LICENSE.md
.