{"id":44930,"library":"faye-redis","title":"Faye Redis","description":"Redis backend engine for Faye, the Bayeux-compatible pub/sub messaging system. Current stable version 0.2.0 is the last release. This package provides a Redis-based engine for scaling Faye across multiple Node.js processes or machines. It uses Redis pub/sub for message distribution and stores client subscriptions. Ideal for applications requiring horizontal scalability with Faye. Compared to in-memory engines, it allows multiple Faye servers to share state. Note: only supports node engines >=0.4.0 (very old). No releases after 2012; consider alternatives like faye-redis-node or modern pub/sub solutions.","status":"deprecated","version":"0.2.0","language":"javascript","source_language":"en","source_url":"git://github.com/faye/faye-redis-node","tags":["javascript","pubsub","bayeux"],"install":[{"cmd":"npm install faye-redis","lang":"bash","label":"npm"},{"cmd":"yarn add faye-redis","lang":"bash","label":"yarn"},{"cmd":"pnpm add faye-redis","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Required for Redis client connection","package":"redis","optional":false},{"reason":"Peer dependency for Faye engine interface","package":"faye","optional":false}],"imports":[{"note":"Package is CommonJS only; ES imports are unsupported. Use require().","wrong":"import { RedisEngine } from 'faye-redis';","symbol":"RedisEngine","correct":"const { RedisEngine } = require('faye-redis');"},{"note":"CommonJS default export. ES import syntax will fail.","wrong":"import RedisEngine from 'faye-redis';","symbol":"default","correct":"const RedisEngine = require('faye-redis');"}],"quickstart":{"code":"const http = require('http');\nconst faye = require('faye');\nconst { RedisEngine } = require('faye-redis');\n\nconst server = http.createServer();\nconst bayeux = new faye.NodeAdapter({ mount: '/faye', timeout: 25 });\nconst redisEngine = new RedisEngine({\n  host: process.env.REDIS_HOST || 'localhost',\n  port: process.env.REDIS_PORT || 6379,\n  password: process.env.REDIS_PASSWORD || '',\n  database: 0,\n  namespace: 'faye:'\n});\n\nbayeux.attach(server);\n// Set the Redis engine on the Faye server\nbayeux.getClient().setEngine(redisEngine);\n\nserver.listen(8000, () => {\n  console.log('Faye server with Redis engine running on port 8000');\n});","lang":"javascript","description":"Sets up a Faye NodeAdapter with Redis engine for horizontal scaling using environment variables for Redis config."},"warnings":[{"fix":"Migrate to alternative libraries like faye-redis-node or use modern pub/sub with socket.io.","message":"Package has not been updated since 2012. No longer maintained and may have security vulnerabilities.","severity":"deprecated","affected_versions":">=0.0.0"},{"fix":"Downgrade Node.js to a compatible version or use a maintained fork.","message":"Requires Node.js >=0.4.0 (very old). Will not work on modern Node.js versions (10+).","severity":"breaking","affected_versions":">=0.2.0"},{"fix":"Call bayeux.attach(server) before bayeux.getClient().setEngine(redisEngine).","message":"The engine must be set after attaching the adapter. Setting it before attach() will cause runtime errors.","severity":"gotcha","affected_versions":">=0.1.0"},{"fix":"Use a fork that supports modern redis driver, or upgrade dependencies.","message":"Uses the old 'redis' npm package version 0.12.x which is unmaintained and may have known vulnerabilities.","severity":"deprecated","affected_versions":">=0.0.0"}],"env_vars":null,"search_vec":"'0.2.0':18 '0.4.0':78 '2012':84 'across':34 'allow':66 'altern':86 'applic':53 'backend':4 'base':29 'bayeux':10,98 'bayeux-compat':9 'client':49 'compar':59 'compat':11 'consid':85 'current':15 'distribut':46 'engin':5,30,64,77 'fay':1,7,33,58,68,89 'faye-redis-nod':88 'horizont':55 'ideal':51 'in-memori':61 'javascript':96 'last':21 'like':87 'machin':39 'memori':63 'messag':13,45 'modern':93 'multipl':35,67 'node':76,91 'node.js':36 'note':73 'old':80 'packag':24 'process':37 'provid':25 'pub/sub':12,43,94 'pubsub':97 'redi':2,3,28,42,90 'redis-bas':27 'releas':22,82 'requir':54 'scalabl':56 'scale':32 'server':69 'share':71 'solut':95 'stabl':16 'state':72 'store':48 'subscript':50 'support':75 'system':14 'use':41 'version':17","created_at":"2026-06-07T12:52:32.533388+00:00","updated_at":"2026-06-07T12:52:32.533388+00:00","problems":[{"fix":"Run 'npm install faye-redis' to install the package.","cause":"Package not installed or not in node_modules.","error":"Error: Cannot find module 'faye-redis'"},{"fix":"Ensure bayeux.attach(server) is called before setEngine, and use Faye 1.x.","cause":"Engine set before adapter is attached, or using wrong Faye version.","error":"TypeError: bayeux.getClient(...).setEngine is not a function"},{"fix":"Start Redis server or check host/port environment variables.","cause":"Redis server is not running or not accessible at the specified host/port.","error":"Error: Redis connection to 127.0.0.1:6379 failed - connect ECONNREFUSED"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"http://github.com/faye/faye-redis-node","github":"git://github.com/faye/faye-redis-node","docs":null,"changelog":null,"pypi":null,"npm":"faye-redis","openapi_spec":null,"status_page":null,"smithery":null,"categories":["messaging"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-07","next_check":"2026-09-05","install_tag":null}}