{"id":18877563,"url":"https://github.com/nftstorage/gateway-load-simulator","last_synced_at":"2026-02-19T01:30:14.899Z","repository":{"id":44617717,"uuid":"440820110","full_name":"nftstorage/gateway-load-simulator","owner":"nftstorage","description":"***Notice: This repository is no longer maintained.***SImulate a load test for the gateway","archived":false,"fork":false,"pushed_at":"2022-02-06T10:30:05.000Z","size":11,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-12-31T02:24:26.470Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/nftstorage.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":"2021-12-22T10:31:06.000Z","updated_at":"2024-07-03T04:57:46.000Z","dependencies_parsed_at":"2022-09-01T04:51:11.414Z","dependency_job_id":null,"html_url":"https://github.com/nftstorage/gateway-load-simulator","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/nftstorage%2Fgateway-load-simulator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nftstorage%2Fgateway-load-simulator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nftstorage%2Fgateway-load-simulator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nftstorage%2Fgateway-load-simulator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nftstorage","download_url":"https://codeload.github.com/nftstorage/gateway-load-simulator/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239837625,"owners_count":19705378,"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-11-08T06:20:02.799Z","updated_at":"2026-02-19T01:30:14.463Z","avatar_url":"https://github.com/nftstorage.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gateway load simulation\n\n\u003e Tool to load test a IPFS gateway backed by a CSV file with CIDs and timestamps.\n\n## CSV format\n\n```csv\nts,cid,path\n\"2021-11-15T09:21:37.554123Z\",\"bafkreidyeivj7adnnac6ljvzj2e3rd5xdw3revw4da7mx2ckrstapoupoq\",\"\"\n```\n\nThe timestamps will be used as a relative time. This tool requires that the timestamps are sorted by timestamp. It will use the first timestamp as the initial date and perform requests with the same cadence as the CSV file states.\n\n## Getting Started\n\nThis tool relies on external services that need to be configured by creating a `.env.local` file as follows:\n\n```env\n# IPFS gateway with support for subdomain as \u003ccid\u003e.ipfs.\u003cIPFS_GATEWAY\u003e\nIPFS_GATEWAY=\"dweb.link\"\n\n# Used for storage\nWEB3_STORAGE_TOKEN=\"\u003cinsert token created from web3.storage\u003e\"\n\n### Running Load tests from CID + path (not for development)\nCSV_DIR_CID=\"\u003cinsert cid\u003e\"\nCSV_FILE_NAME=\"\u003cinsert file name\u003e\"\n```\n\n## CLI\n\n### Load test from a CSV file\n\nRun a load test from a local CSV file.\n\n```sh\ngw-load start fixtures/gateway.csv\n```\n\n### Load test from Partial CSV files\n\nFor better simulations, multiple locations should be used to perform the gateway requests. This tool supports CSV random splitting into multiple files that can then be used in multiple machines.\n\nFor splitting a CSV you just need to provide the complete CSV and the number of resulting CSV files to create. The CSV files will be stored in web3.storage so that they can then be easily used from this tool.\n\n```sh\ngw-load split fixtures/gateway.csv 2\n```\n\nThe CSV files are stored as `{number}.csv` within the filer.\n\nIn different machines it is now possible to run the load test as follows:\n\n```sh\ngw-load start-w3 bafybeieems2dpnxyb2as3g7zx4g3qiawz2a47iw45cjjw62o6bxftcvvgu 0.csv\n```\n\n```sh\ngw-load start-w3 bafybeieems2dpnxyb2as3g7zx4g3qiawz2a47iw45cjjw62o6bxftcvvgu 1.csv\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnftstorage%2Fgateway-load-simulator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnftstorage%2Fgateway-load-simulator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnftstorage%2Fgateway-load-simulator/lists"}