Vegeta触ってみる
Vegeta
- golang 用の負荷試験ツール github.com
Install
╰─$ brew update && brew install vegeta
Run
10request/sec を 5秒間行う
╰─$ echo "GET https://hogehoge.com" | vegeta attack -rate=10 -duration=5s | tee result.bin
Result
╰─$ vegeta report result.bin Requests [total, rate, throughput] 50, 10.20, 10.16 Duration [total, attack, wait] 4.921s, 4.903s, 18.422ms Latencies [min, mean, 50, 90, 95, 99, max] 15.858ms, 28.547ms, 19.547ms, 31.033ms, 41.625ms, 240.18ms, 240.18ms Bytes In [total, mean] 0, 0.00 Bytes Out [total, mean] 0, 0.00 Success [ratio] 100.00% Status Codes [code:count] 200:50 Error Set:
Result(html形式)
cat result.bin | vegeta plot > result_plot.html