{"id":23186959,"url":"https://github.com/caffeinum/redis-nodejs-proxy","last_synced_at":"2025-04-05T05:10:45.046Z","repository":{"id":44029367,"uuid":"227225678","full_name":"caffeinum/redis-nodejs-proxy","owner":"caffeinum","description":"Caching NodeJS proxy over Redis instance. Plus Docker!","archived":false,"fork":false,"pushed_at":"2023-01-24T00:55:26.000Z","size":681,"stargazers_count":0,"open_issues_count":15,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-10T13:09:15.818Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/caffeinum.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-12-10T22:12:59.000Z","updated_at":"2020-05-27T00:47:11.000Z","dependencies_parsed_at":"2023-01-31T14:05:17.274Z","dependency_job_id":null,"html_url":"https://github.com/caffeinum/redis-nodejs-proxy","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caffeinum%2Fredis-nodejs-proxy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caffeinum%2Fredis-nodejs-proxy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caffeinum%2Fredis-nodejs-proxy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caffeinum%2Fredis-nodejs-proxy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/caffeinum","download_url":"https://codeload.github.com/caffeinum/redis-nodejs-proxy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247289429,"owners_count":20914464,"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","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":[],"created_at":"2024-12-18T10:18:16.086Z","updated_at":"2025-04-05T05:10:45.024Z","avatar_url":"https://github.com/caffeinum.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# redis-nodejs-proxy\n\n## Intro\n\nSometimes even [Redis](https://redis.io/) is too slow. So we cache his requests in NodeJS.\n\n## Run\n\nProject uses `Docker` and has `Makefile`. You can run plain JS, if you prefer, or run out-of-the-box Dockerized setup.\n\n### Running with NodeJS\n\n1. Configure settings in `.env` file.\n\n```\n# default values:\nPORT=3000\nREDIS_ADDR=127.0.0.1\nREDIS_PORT=6379\nCACHE_EXPIRY_TIME=3600\nCACHE_CAPACITY=10000\n```\n\n2. Install Node packages and build app.\n\n```bash\nnpm i\nnpm run start # in dev mode\n```\n\n3. Run built version\n\n```bash\nnpm run build\nnode dist\n```\n\n4. Test:\n\n```bash\ncurl localhost:3000/test1\ncurl localhost:3000/test1\ncurl localhost:3000/test2\n```\n\n### Running with Docker\n\n1. Setup environment variables for Docker compose:\n\n```yaml\n# docker-compose.yml\n...\n  environment:\n    - PORT=3000\n    - REDIS_ADDR=host.docker.internal\n    - REDIS_PORT=6379\n    - CACHE_EXPIRY_TIME=3600\n    - CACHE_CAPACITY=10000\n    - NODE_ENV=production\n...\n```\n\n2. Run Docker containers:\n\n```bash\nmake\n```\n\n3. Run tests\n\n```bash\nmake test\n```\n\n## Contribution\n\nFeel free to comment\n\n## LICENSE\n\n[LICENSE]\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcaffeinum%2Fredis-nodejs-proxy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcaffeinum%2Fredis-nodejs-proxy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcaffeinum%2Fredis-nodejs-proxy/lists"}