{"id":13413618,"url":"https://github.com/ian-kent/linkio","last_synced_at":"2025-06-11T19:07:28.336Z","repository":{"id":25026627,"uuid":"28446072","full_name":"ian-kent/linkio","owner":"ian-kent","description":"Simulate network link speed","archived":false,"fork":false,"pushed_at":"2017-08-07T20:57:56.000Z","size":5,"stargazers_count":53,"open_issues_count":0,"forks_count":7,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-12T05:53:53.464Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","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/ian-kent.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":"2014-12-24T10:50:03.000Z","updated_at":"2024-03-05T08:15:57.000Z","dependencies_parsed_at":"2022-07-24T03:46:33.665Z","dependency_job_id":null,"html_url":"https://github.com/ian-kent/linkio","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ian-kent/linkio","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ian-kent%2Flinkio","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ian-kent%2Flinkio/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ian-kent%2Flinkio/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ian-kent%2Flinkio/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ian-kent","download_url":"https://codeload.github.com/ian-kent/linkio/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ian-kent%2Flinkio/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259320531,"owners_count":22840003,"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-07-30T20:01:44.676Z","updated_at":"2025-06-11T19:07:28.319Z","avatar_url":"https://github.com/ian-kent.png","language":"Go","funding_links":[],"categories":["Testing","网络","Networking","\u003cspan id=\"网络-networking\"\u003e网络 Networking\u003c/span\u003e","网络相关库","網絡","Relational Databases"],"sub_categories":["Network-specific testing","音译","Transliteration","Strings","Advanced Console UIs","\u003cspan id=\"高级控制台用户界面-advanced-console-uis\"\u003e高级控制台用户界面 Advanced Console UIs\u003c/span\u003e","Uncategorized","暂未分类","暂未分类这些库被放在这里是因为其他类别似乎都不适合。","交流","高级控制台界面","高級控制台界面"],"readme":"linkio [![GoDoc](https://godoc.org/github.com/ian-kent/linkio?status.svg)](https://godoc.org/github.com/ian-kent/linkio) [![Build Status](https://travis-ci.org/ian-kent/linkio.svg?branch=master)](https://travis-ci.org/ian-kent/linkio)\n======\n\nlinkio provides an io.Reader and io.Writer that simulate a network connection of a certain speed, e.g. to simulate a mobile connection.\n\n### Quick start\n\nYou can use `linkio` to wrap existing io.Reader and io.Writer interfaces:\n\n```go\n// Create a new link at 512kbps\nlink = linkio.NewLink(512 * linkio.KilobitPerSecond)\n\n// Open a connection\nconn, err := net.Dial(\"tcp\", \"google.com:80\")\nif err != nil {\n  // handle error\n}\n\n// Create a link reader/writer\nlinkReader := link.NewLinkReader(io.Reader(conn))\nlinkWriter := link.NewLinkWriter(io.Writer(conn))\n\n// Use them as you would normally...\nfmt.Fprintf(linkWriter, \"GET / HTTP/1.0\\r\\n\\r\\n\")\nstatus, err := bufio.NewReader(linkReader).ReadString('\\n')\n\n```\n\n### History and license\n\nThis repository is a fork of [Jeff R. Allen's\nlinkio](https://github.com/jeffallen/jra-go/tree/master/linkio). linkio\nwas brought into the world to help make a proxy to simulate slow\nInternet links (see [this blog\nposting](https://blog.nella.org/a-rate-limiting-http-proxy-in-go/)).\n\nJeff's linkio was licensed via the [BSD 3-clause\nlicense](http://opensource.org/licenses/BSD-3-Clause).\n\nAny modifications since the initial commit are Copyright ©‎ 2014, Ian\nKent (http://iankent.uk), and are released under the terms of the [MIT\nLicense](http://opensource.org/licenses/MIT).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fian-kent%2Flinkio","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fian-kent%2Flinkio","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fian-kent%2Flinkio/lists"}