{"id":18078940,"url":"https://github.com/fengkx/cacheman-level","last_synced_at":"2026-04-28T18:35:19.286Z","repository":{"id":34147574,"uuid":"170494275","full_name":"fengkx/cacheman-level","owner":"fengkx","description":"Cacheman engine using leveldb","archived":false,"fork":false,"pushed_at":"2023-02-06T21:00:44.000Z","size":307,"stargazers_count":1,"open_issues_count":3,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-03-01T09:56:23.759Z","etag":null,"topics":["cache","cacheman","npm-package"],"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/fengkx.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-02-13T11:11:41.000Z","updated_at":"2023-03-07T02:38:20.000Z","dependencies_parsed_at":"2023-02-10T06:15:15.897Z","dependency_job_id":null,"html_url":"https://github.com/fengkx/cacheman-level","commit_stats":null,"previous_names":["fengkx/cacheman-leveldb"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/fengkx/cacheman-level","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fengkx%2Fcacheman-level","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fengkx%2Fcacheman-level/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fengkx%2Fcacheman-level/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fengkx%2Fcacheman-level/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fengkx","download_url":"https://codeload.github.com/fengkx/cacheman-level/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fengkx%2Fcacheman-level/sbom","scorecard":{"id":396788,"data":{"date":"2025-08-11","repo":{"name":"github.com/fengkx/cacheman-level","commit":"611efdee49268710ec9e4904732f179f2df2348b"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/4 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 26 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-18T19:12:46.422Z","repository_id":34147574,"created_at":"2025-08-18T19:12:46.423Z","updated_at":"2025-08-18T19:12:46.423Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32394466,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-28T14:34:11.604Z","status":"ssl_error","status_checked_at":"2026-04-28T14:32:37.009Z","response_time":56,"last_error":"SSL_read: 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":["cache","cacheman","npm-package"],"created_at":"2024-10-31T12:16:46.051Z","updated_at":"2026-04-28T18:35:19.271Z","avatar_url":"https://github.com/fengkx.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cacheman-level\n\nStandalone caching library for Node.JS and also cache engine for [cacheman](https://github.com/cayasso/cacheman) using LevelDB specifically [level](https://www.npmjs.com/package/level).\n\n[![NPM](https://nodei.co/npm/cacheman-level.png)](https://nodei.co/npm/cacheman-level/)\n[![Build Status](https://travis-ci.org/fengkx/cacheman-level.svg?branch=master)](https://travis-ci.org/fengkx/cacheman-level)\n[![Coverage Status](https://coveralls.io/repos/github/fengkx/cacheman-level/badge.svg?branch=master)](https://coveralls.io/github/fengkx/cacheman-level?branch=master)\n\n## Instalation\n\n```bash\n$ npm install cacheman-level\n```\n\n## Usage\n\n**Promise is support**\n\n```js\nconst CachemanLevel = require('cacheman-level');\nconst cache = new CachemanLevel('./DS_Store'); //location\n;(async () =\u003e {\n    // set the value\n    await cache.set('my key', { foo: 'bar' });\n    const value = await cache.get('my key');\n    console.log(value); //-\u003e {foo:\"bar\"}\n    \n})()\n\n```\n\n\n```javascript\nconst CachemanLevel = require('cacheman-level');\nconst cache = new CachemanLevel('./DS_Store'); //location\n\n// set the value\ncache.set('my key', { foo: 'bar' }, function(error) {\n    if (error) throw error;\n\n    // get the value\n    cache.get('my key', function(error, value) {\n        if (error) throw error;\n\n        console.log(value); //-\u003e {foo:\"bar\"}\n\n        // delete entry\n        cache.del('my key', function(error) {\n            if (error) throw error;\n\n            console.log('value deleted');\n        });\n    });\n});\n```\n\n## API\n\n### CachemanLevel(location, [options, error-handler])\n\nCreate `cacheman-level` instance. `options` are [level](https://www.npmjs.com/package/level) options including `checkFrequency`.\n\n```javascript\nconst options = {\n    prefix: 'cache',\n    checkFrequency: 15 * 1000\n};\n\nconst cache = new CachemanLevel(location, options);\n```\n\nmore options get be found [here](https://www.npmjs.com/package/leveldown#ctor)\n\n### cache.set(key, value, [ttl, [fn]])\n\nStores or updates a value.\n\n```javascript\ncache.set('foo', { a: 'bar' }, function(err, value) {\n    if (err) throw err;\n    console.log(value); //-\u003e {a:'bar'}\n});\n```\n\nOr add a TTL(Time To Live) in seconds like this:\n\n```javascript\n// key will expire in 60 seconds\ncache.set('foo', { a: 'bar' }, 60, function(err, value) {\n    if (err) throw err;\n    console.log(value); //-\u003e {a:'bar'}\n});\n```\n\n### cache.get(key, fn)\n\nRetrieves a value for a given key, if there is no value for the given key a null value will be returned.\n\n```javascript\ncache.get(function(err, value) {\n    if (err) throw err;\n    console.log(value);\n});\n```\n\n### cache.del(key, [fn])\n\nDeletes a key out of the cache.\n\n```javascript\ncache.del('foo', function(err) {\n    if (err) throw err;\n    // foo was deleted\n});\n```\n\n### cache.clear([fn])\n\nClear the cache entirely, throwing away all values.\n\n```javascript\ncache.clear(function(err) {\n    if (err) throw err;\n    // cache is now clear\n});\n```\n\n## Run tests\n\n```bash\n$ npm test\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffengkx%2Fcacheman-level","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffengkx%2Fcacheman-level","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffengkx%2Fcacheman-level/lists"}