{"id":46769,"library":"volos-cache-redis","title":"Volos Cache Redis","description":"Redis-backed caching library for the Volos system. Version 0.10.1 provides a simple cache interface with configurable TTL, encoding, and Redis connection settings (host, port, DB). It is a part of the Apigee Volos ecosystem, offering a consistent API via volos-cache-common. Supports namespaced caches. Note: this package is deprecated and no longer maintained; users should migrate to alternative caching solutions.","status":"deprecated","version":"0.10.1","language":"javascript","source_language":"en","source_url":"https://github.com/apigee/volos","tags":["javascript","cache","redis"],"install":[{"cmd":"npm install volos-cache-redis","lang":"bash","label":"npm"},{"cmd":"yarn add volos-cache-redis","lang":"bash","label":"yarn"},{"cmd":"pnpm add volos-cache-redis","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Provides the common cache interface that this module extends","package":"volos-cache-common","optional":false},{"reason":"Required for Redis database driver","package":"redis","optional":false}],"imports":[{"note":"ESM import example; the library may also support CommonJS require.","wrong":"const volos = require('volos-cache-redis');","symbol":"createCache","correct":"import { createCache } from 'volos-cache-redis'"},{"note":"CommonJS require of default export; note that createCache is a method on the default export.","wrong":"const cache = require('volos-cache-redis').createCache();","symbol":"default","correct":"import volosCacheRedis from 'volos-cache-redis'; const cache = volosCacheRedis.createCache();"},{"note":"The main export is an object with a create method; named export 'create' does not exist.","wrong":"import { create } from 'volos-cache-redis';","symbol":"create","correct":"const cacheModule = require('volos-cache-redis'); cacheModule.create('myCache', options);"}],"quickstart":{"code":"const cacheModule = require('volos-cache-redis');\nconst options = {\n  ttl: 5000,\n  host: process.env.REDIS_HOST ?? '127.0.0.1',\n  port: parseInt(process.env.REDIS_PORT ?? '6379'),\n  db: 0\n};\nconst cache = cacheModule.create('myCache', options);\n\ncache.set('key', 'value', function(err) {\n  if (err) console.error(err);\n  else console.log('Value set');\n});\n\ncache.get('key', function(err, value) {\n  if (err) console.error(err);\n  else console.log('Value:', value);\n});","lang":"javascript","description":"Shows how to create a Redis cache instance with a TTL, set a key-value pair, and retrieve it asynchronously."},"warnings":[{"fix":"Migrate to an alternative caching library such as ioredis or node-cache-manager with Redis store.","message":"Package is deprecated; no longer actively maintained.","severity":"deprecated","affected_versions":">=0.0.0"},{"fix":"Ensure you pass a unique string as the first argument to create.","message":"create function must be called with a name and options; the name acts as a namespace.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Expect Buffer values from get(); convert to string if needed using .toString().","message":"The library forces return_buffers to true in Redis options.","severity":"gotcha","affected_versions":">=0.0.0"}],"env_vars":null,"search_vec":"'0.10.1':14 'altern':65 'api':43 'apige':37 'back':6 'cach':2,7,18,47,51,66,69 'common':48 'configur':21 'connect':26 'consist':42 'db':30 'deprec':56 'ecosystem':39 'encod':23 'host':28 'interfac':19 'javascript':68 'librari':8 'longer':59 'maintain':60 'migrat':63 'namespac':50 'note':52 'offer':40 'packag':54 'part':34 'port':29 'provid':15 'redi':3,5,25,70 'redis-back':4 'set':27 'simpl':17 'solut':67 'support':49 'system':12 'ttl':22 'user':61 'version':13 'via':44 'volo':1,11,38,46 'volos-cache-common':45","created_at":"2026-06-07T13:01:32.298984+00:00","updated_at":"2026-06-07T13:01:32.298984+00:00","problems":[{"fix":"Start Redis server or configure correct host/port in options.","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"},{"fix":"Use default export: const cacheModule = require('volos-cache-redis'); then cacheModule.create(...).","cause":"Incorrect import: trying to import named export 'create' which does not exist.","error":"TypeError: cacheModule.create is not a function"}],"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":"https://github.com/apigee/volos","github":"https://github.com/apigee/volos","docs":null,"changelog":null,"pypi":null,"npm":"volos-cache-redis","openapi_spec":null,"status_page":null,"smithery":null,"categories":["database"],"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}}