goreplay工具使用

  1. 輸出到控制檯
    ./goreplay --input-raw :8080 --output-stdout

  2. 輸出到服務器
    ./goreplay --input-raw :8080 --output-http="http://localhost:8080"

  3. 保存到文件
    ./goreplay --input-raw :8080 --output-file=requests.gor
    ./goreplay --input-file requests.gor --output-http="http://localhost:8080"

  4. 啓用會話識別:
    --recognize-tcp-sessions

    GoReplay不會跟蹤響應,您可以使用--output-http-track-response

5 性能測試
./goreplay --input-file "requests.gor|200%" --input-file-loop --output-http="http://localhost:8080"

請求重寫
goreplay --input-raw :8080 --output-stdout --http-allow-url /homepage/v1/check --http-rewrite-url /homepage/v1/check:/homepage/v2/check

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章