UNPKG

redis-smq

Version:

A high-performance, reliable, and scalable message queue for Node.js.

16 lines 553 B
import { CallbackEmptyReplyError, } from 'redis-smq-common'; import { redisKeys } from '../../common/redis/redis-keys/redis-keys.js'; export function _getQueues(client, cb) { const { keyQueues } = redisKeys.getMainKeys(); client.sscanAll(keyQueues, {}, (err, reply) => { if (err) cb(err); else if (!reply) cb(new CallbackEmptyReplyError()); else { const queues = reply.map((i) => JSON.parse(i)); cb(null, queues); } }); } //# sourceMappingURL=_get-queues.js.map