{"id":18812759,"url":"https://github.com/alexdonh/adonis-cache","last_synced_at":"2026-05-15T23:04:34.688Z","repository":{"id":71796907,"uuid":"219450568","full_name":"alexdonh/adonis-cache","owner":"alexdonh","description":"Another cache provider for AdonisJs. Supports Object, File, Db and Redis cache. With cache dependencies!","archived":false,"fork":false,"pushed_at":"2019-11-13T06:22:41.000Z","size":56,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-05-22T04:09:38.472Z","etag":null,"topics":["adonis-framework","adonisjs","cache","data","dependency","redis","storing"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alexdonh.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-11-04T08:19:05.000Z","updated_at":"2019-11-13T06:22:43.000Z","dependencies_parsed_at":null,"dependency_job_id":"50f22f3e-0c6d-4d3b-81eb-51c3b6c674ab","html_url":"https://github.com/alexdonh/adonis-cache","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/alexdonh/adonis-cache","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexdonh%2Fadonis-cache","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexdonh%2Fadonis-cache/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexdonh%2Fadonis-cache/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexdonh%2Fadonis-cache/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alexdonh","download_url":"https://codeload.github.com/alexdonh/adonis-cache/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexdonh%2Fadonis-cache/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33082771,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-15T20:25:35.270Z","status":"ssl_error","status_checked_at":"2026-05-15T20:25:34.732Z","response_time":103,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["adonis-framework","adonisjs","cache","data","dependency","redis","storing"],"created_at":"2024-11-07T23:35:00.300Z","updated_at":"2026-05-15T23:04:34.656Z","avatar_url":"https://github.com/alexdonh.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Adonis Cache\n\nAnother cache provider for [AdonisJs](https://github.com/adonisjs/adonis-framework). Supports Object, File, Db and Redis data store. It also supports cache dependencies.\n\n## Installation\n\n```bash\n$ adonis install git+https://github.com/alexdonh/adonis-cache.git --as=adonis-cache\n```\n\nInstall optional dependencies to use. For example, install\n\n```bash\n$ npm i fs-extra microtime moment proper-lockfile\n```\n\nto use file store caching.\n\n## Setup\n\n1. Register cache providers in `start/app.js` file.\n\n```js\nconst providers = [\n  ...\n  '@adonisjs/lucid/providers/LucidProvider',\n  'adonis-cache/providers/CacheProvider'\n]\n\nconst aceProviders = [\n  ...\n  '@adonisjs/lucid/providers/MigrationsProvider',\n  'adonis-cache/providers/CommandsProvider'\n]\n```\n\n4. Run the migrations if using db store cache. See [https://adonisjs.com/docs/4.1/migrations](https://adonisjs.com/docs/4.1/migrations)\n\n```bash\n$ adonis migration:run\n```\n\n## Usage\n\n```js\nconst Cache = use('Adonis/Addons/Cache') // or alias: use('Cache')\n\n// set cache\nawait Cache.set('key', 'This is a value', 60 * 60 * 24) // 24 hours\n\n// get cache\nawait Cache.get('key')\n\n// add cache, error if key exists\nawait Cache.add('key', something)\n\n// check if cache exists\nawait Cache.exists('key')\n\n// delete cache\nawait Cache.delete('key')\n\n// flush all caches\nawait Cache.flush()\n\n// use another cache store 'key', 'db', 'object', 'redis', or your own custom store\nawait Cache.store('file').get('key')\n\n```\n\n## Register a custom cache store\n\nUpdating...\n\n## Credits\n\n- [Alex Do](https://github.com/alexdonh)\n\n## Support\n\nHaving trouble? [Open an issue](https://github.com/alexdonh/adonis-cache/issues/new)!\n\n## License\n\nThe MIT License (MIT). See [License File](LICENSE) for more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexdonh%2Fadonis-cache","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falexdonh%2Fadonis-cache","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexdonh%2Fadonis-cache/lists"}