co-warlock
v0.1.0
Published
co wrapper for node-redis-warlock (Battle-hardened distributed locking using redis)
Downloads
3
Readme
co-warlock
Usage
// wrap node-redis-warlock
var Warlock = require('co-warlock')( require('node-redis-warlock') )
// create new instance
var warlock = Warlock( redisClient )
// try to yield lock
var unlock = yield warlock.lock('try:to:lock', 10000)
Reference
https://github.com/TheDeveloper/warlock