{"id":13740134,"url":"https://github.com/crossoverjie/ptg","last_synced_at":"2025-04-09T10:08:57.296Z","repository":{"id":37297250,"uuid":"415986304","full_name":"crossoverJie/ptg","owner":"crossoverJie","description":"💥Performance testing tool (Go), It is also a GUI gRPC client.","archived":false,"fork":false,"pushed_at":"2022-07-11T05:42:42.000Z","size":5980,"stargazers_count":329,"open_issues_count":5,"forks_count":36,"subscribers_count":10,"default_branch":"main","last_synced_at":"2025-04-02T03:24:51.177Z","etag":null,"topics":["benchmark","golang","grpc","grpc-client","grpc-gui","http","performance-testing"],"latest_commit_sha":null,"homepage":"https://crossoverjie.top/2021/11/28/go/go-grpc-client-gui/","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/crossoverJie.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-10-11T15:32:11.000Z","updated_at":"2025-03-26T20:06:23.000Z","dependencies_parsed_at":"2022-06-27T21:22:58.915Z","dependency_job_id":null,"html_url":"https://github.com/crossoverJie/ptg","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crossoverJie%2Fptg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crossoverJie%2Fptg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crossoverJie%2Fptg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crossoverJie%2Fptg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/crossoverJie","download_url":"https://codeload.github.com/crossoverJie/ptg/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248018060,"owners_count":21034048,"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":["benchmark","golang","grpc","grpc-client","grpc-gui","http","performance-testing"],"created_at":"2024-08-03T04:00:43.133Z","updated_at":"2025-04-09T10:08:57.275Z","avatar_url":"https://github.com/crossoverJie.png","language":"Go","readme":"# ptg\nPerformance testing tool (Go), It is also a **GUI** `gRPC` client.\n\nTest the `gRPC` service like `postman`.\n\n\n![](pic/show.gif)\n![](pic/ptg.gif)\n![](pic/search.gif)\n\u003cdetails\u003e\n  \u003csummary\u003eMore screenshot\u003c/summary\u003e\n   \u003cimg src=\"pic/server-stream-min.gif\"\u003e\n   \u003cimg src=\"pic/client-stream-min.gif\"\u003e\n   \u003cimg src=\"pic/bd-stream-min.gif\"\u003e   \n\n\u003c/details\u003e\n\n\n# Features\n- [x] CLI performance test support.\n- [x] GUI support.\n- [x] Metadata support.\n- [x] Data persistence.\n- [x] Search history.\n- [X] Stream call.\n- [ ] Benchmark GUI.\n\n# Install\n\n## CLI app\n```go\ngo get github.com/crossoverJie/ptg\n```\n\n```shell script\nwget https://github.com/crossoverJie/ptg/releases/download/${version}/ptg-${os}-${version}.tar.gz\n```\n\n## GUI app\n\nTo download the installer, go to the [Releases Page](https://github.com/crossoverJie/ptg/releases).\n\n## Build from source\n\n```shell\ngit clone git@github.com:crossoverJie/ptg.git\ncd ptg\nmake release\nmake pkg-win\nmake pkg-macos\n```\n\n\n# Usage\n\n```shell script\nNAME:\n   ptg - Performance testing tool (Go)\n\nUSAGE:\n   ptg [global options] command [command options] [arguments...]\n\nCOMMANDS:\n   help, h  Shows a list of commands or help for one command\n\nGLOBAL OPTIONS:\n   --thread value, -t value              -t 10 (default: 1 thread)\n   --Request value, --proto value        -proto http/grpc (default: http)\n   --protocol value, --pf value          -pf /file/order.proto\n   --fully-qualified value, --fqn value  -fqn package.Service.Method\n   --duration value, -d value            -d 10s (default: Duration of test in seconds, Default 10s)\n   --request value, -c value             -c 100 (default: 100)\n   --HTTP value, -M value                -m GET (default: GET)\n   --bodyPath value, --body value        -body bodyPath.json\n   --header value, -H value              HTTP header to add to request, e.g. \"-H Content-Type: application/json\"\n   --target value, --tg value            http://gobyexample.com/grpc:127.0.0.1:5000\n   --help, -h                            show help (default: false)\n```\n## http\n```shell script\nptg -t 20 -d 10 -proto http -tg \"http://gobyexample.com\"\n```\n\nBenchmark test for 10 seconds, using 20 goroutines.\n\noutput:\n```shell script\nRequesting: http://gobyexample.com  \u003c---------------\u003e 1 p/s 100.00%\n\n43 requests in 10 seconds, 13.88MB read.\nAvg Req Time:           358.512071ms\nFastest Request:        93.518704ms\nSlowest Request:        840.680771ms\nNumber of Errors:       0\n```\n\n\u003e POST example\n\n```shell script\nptg -t 2 -proto http -c 2 -M POST -H \"Content-Type: application/json\"  -body test.json -tg \"http://xx/create\"\n```\n\n## gRPC(unary call)\n\n```shell script\nptg -t 10 -c 100 -proto grpc  -pf /xx/xx.proto -fqn hello.Hi.Say -body test.json  -tg \"127.0.0.1:5000\"\n```\n\noutput:\n```shell script\nthread: 10, duration: 0, count 100\nRequesting: 127.0.0.1:5000  \u003c---------------\u003e 102 p/s 100.00%\n100 requests in 11 seconds, 230.6kB read, and cost 1 second.\nAvg Req Time:           116.602652ms\nFastest Request:        111.563179ms\nSlowest Request:        128.587886ms\nNumber of Errors:       0\n```\n\n\n# Acknowledgements\n- [go-wrk](https://github.com/tsliwowicz/go-wrk)\n- [bloomrpc](https://github.com/bloomrpc/bloomrpc)\n\n","funding_links":[],"categories":["Tools"],"sub_categories":["GUI"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrossoverjie%2Fptg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcrossoverjie%2Fptg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrossoverjie%2Fptg/lists"}