{"id":39401640,"url":"https://github.com/cachebag/rust-line","last_synced_at":"2026-01-18T03:24:40.921Z","repository":{"id":306292192,"uuid":"1025591946","full_name":"cachebag/rust-line","owner":"cachebag","description":"HTTP server built in Rust from scratch, for educational purposes.","archived":false,"fork":false,"pushed_at":"2025-09-09T03:25:34.000Z","size":51,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-09-09T06:24:39.768Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","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/cachebag.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-07-24T13:44:10.000Z","updated_at":"2025-09-09T03:25:38.000Z","dependencies_parsed_at":"2025-08-27T15:28:49.804Z","dependency_job_id":"97ea3bb8-924d-4940-aa4a-c16218739ea5","html_url":"https://github.com/cachebag/rust-line","commit_stats":null,"previous_names":["cachebag/rustline","cachebag/rust-line"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cachebag/rust-line","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cachebag%2Frust-line","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cachebag%2Frust-line/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cachebag%2Frust-line/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cachebag%2Frust-line/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cachebag","download_url":"https://codeload.github.com/cachebag/rust-line/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cachebag%2Frust-line/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28528038,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-18T00:39:45.795Z","status":"online","status_checked_at":"2026-01-18T02:00:07.578Z","response_time":98,"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":[],"created_at":"2026-01-18T03:24:40.843Z","updated_at":"2026-01-18T03:24:40.907Z","avatar_url":"https://github.com/cachebag.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rust-line\n\nA minimal HTTP server built from scratch in Rust\n\n## Endpoints\n- `GET /ping` – returns `PONG`.\n- `GET /uptime` – returns server uptime.\n- `GET /echo/\u003ctext\u003e` – echoes `\u003ctext\u003e` back.\n- `GET /user-agent` – returns the `User-Agent` header from the request.\n- `GET /files` - Returns content of a specified file\n\n## Performance (WIP)\n`perf.sh` will use `wrk` to run a performance test on the server. It runs 250 connections on 10 threads. It serves `index.html`.\n```bash\nchmod +x perf.sh\n./perf.sh\n```\n#### Current Benchmarks (may vary based on your machine's specs):\n- ~100,000+ requests/second\n- ~2.4ms average response time\n- Tests 250 concurrent connections on 10 threads\n- Throughout -\u003e 6.8MB/s\n\u003cbr\u003e\n\u003cimg width=\"737\" height=\"326\" alt=\"image\" src=\"https://github.com/user-attachments/assets/8f2aa02c-fe1d-4acb-9dee-dd99a8aba900\" /\u003e\n\n###### **Device Specs**: \n\u003cimg width=\"625\" height=\"531\" alt=\"image\" src=\"https://github.com/user-attachments/assets/c44c6a65-9c34-406b-b37d-25faa3e5a338\" /\u003e\n\n## Run\n\nNo directory specified\n```bash\ncargo run --release -- ns \n````\n\nSet cwd\n```bash\ncargo run --release -- directory /path/to/dir\n````\n\nDefault cwd to `.`\n```bash\ncargo run --release -- directory \n````\n\n## Test (WIP)\n\n**Integration Tests**\n```bash\ncargo test --test load_test -- --nocapture\n```\n**Unit Tests**\n```bash\ncargo test --lib\n```\n\n**Everything**\n```bash\ncargo test\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcachebag%2Frust-line","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcachebag%2Frust-line","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcachebag%2Frust-line/lists"}