hey压测工具
地址
参数 | 解释 |
---|---|
-n | 总请求数目 |
-c | 并发数目 |
-q | 单个work的qps |
-z | 持续时常,和-n参数可以选择一个使用 |
-o | 输出格式,支持标准和csv两种格式 |
-m | HTTP method |
-H | 自定义的请求头 |
-t | 超时时间 |
-d | http body |
-D | http body文件地址 |
-a | Basic authentication |
-x | http代理地址 |
-h2 | 开启HTTP/2 |
-disable-compression | Disable compression. |
-disable-keepalive | connections between different HTTP requests. |
-disable-redirects | Disable following of HTTP redirects |
-cpus | 使用cpu资源数目 |
hey是一款使用Golang开发的HTTP压力测试工具,可作为ApacheBench (ab)替代品。
安装hey
以下使用Linux 64位系统,如果您是其它操作系统,请自行前往hey项目地址下载对应客户端。
作者已经提供编译好的二进制包,可直接下载使用。
如果是其它操作系统,请对号入座:
Linux 64-bit: https://hey-release.s3.us-east-2.amazonaws.com/hey_linux_amd64
Mac 64-bit: https://hey-release.s3.us-east-2.amazonaws.com/hey_darwin_amd64
Windows 64-bit: https://hey-release.s3.us-east-2.amazonaws.com/hey_windows_amd64
Last updated