ioredis + logging
📣 💼 💰Looking for a tech job? Try our reverse recruiting service.
This module exports one function:
vr = makeVerboseRedis(how)
how should be a config object with these keys:
logPrefix: Prefix for log and error messages. Required.
port: Which Redis server to use. Optional.
The lower level redis connection. Can be used to access APIs that don't have a verbose wrapper yet.
Terminate the redis connection and clean up. Returns a Promise for being done with cleanup.
exSet = vr.makeExpiringSetter(expirySec[, cond])
Returns an async function
(key, val) that sets a key in redis that
cond can be a redis set condition like
exSet returns a Promise for a boolean, whether the key was set.