{"id":24383467,"url":"https://github.com/firstandthird/hapi-cache-stats","last_synced_at":"2025-12-25T08:18:43.421Z","repository":{"id":54123515,"uuid":"92477812","full_name":"firstandthird/hapi-cache-stats","owner":"firstandthird","description":null,"archived":false,"fork":false,"pushed_at":"2023-01-11T11:45:24.000Z","size":250,"stargazers_count":0,"open_issues_count":5,"forks_count":0,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-12T17:22:53.910Z","etag":null,"topics":["hapi-plugin","hapi-v17","has-tests","needs-coverage"],"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/firstandthird.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}},"created_at":"2017-05-26T06:06:21.000Z","updated_at":"2021-03-09T02:18:29.000Z","dependencies_parsed_at":"2023-02-09T02:45:28.891Z","dependency_job_id":null,"html_url":"https://github.com/firstandthird/hapi-cache-stats","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/firstandthird/hapi-cache-stats","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstandthird%2Fhapi-cache-stats","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstandthird%2Fhapi-cache-stats/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstandthird%2Fhapi-cache-stats/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstandthird%2Fhapi-cache-stats/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/firstandthird","download_url":"https://codeload.github.com/firstandthird/hapi-cache-stats/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstandthird%2Fhapi-cache-stats/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28024527,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-12-25T02:00:05.988Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["hapi-plugin","hapi-v17","has-tests","needs-coverage"],"created_at":"2025-01-19T10:14:33.493Z","updated_at":"2025-12-25T08:18:43.399Z","avatar_url":"https://github.com/firstandthird.png","language":"JavaScript","readme":"# hapi-cache-stats\n\nhapi-cache-stats is a library that monitors the ratio of hits:gets\nfor your server method caches.  When a method's ratios fall below a given threshold\nit will log the hit:get ratio and the stale:get ratio.\n\n## Installation\n\n```console\n  npm install hapi-cache-stats\n```\n\n## Usage\n\n```js\nawait server.register({\n  plugin: require('hapi-cache-stats'),\n  options: {\n    interval: 500,\n    threshold: 0.5\n  }\n});\n```\n\nAnd every server method that has cahcing enabled will be polled every 500 milliseconds,\nif the ratio of hits:gets drops below _threshold_ it will notify you via server.log.\n\n## options\n\n- __interval__\n\n   Report rate in milliseconds, default is 60000.\n\n- __verbose__\n\n  Set to true to log the hit:get and also the stale:get ratio every round.\n\n- __threshold__\n\n    Threshold as a value between 0.0 and 1.0.  When the hit:get ratio drops below this\n    thresold hapi-cache-stats will announce it via server.log.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirstandthird%2Fhapi-cache-stats","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffirstandthird%2Fhapi-cache-stats","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirstandthird%2Fhapi-cache-stats/lists"}