摘要:
goreplay几种engine的区别 capture.go中的引擎类型 func (eng *EngineType) Set(v string) error { switch v { case "", "libpcap": *eng = EnginePcap case "pcap_file": * 阅读全文
:: :: :: :: :: 管理 |
摘要:
goreplay几种engine的区别 capture.go中的引擎类型 func (eng *EngineType) Set(v string) error { switch v { case "", "libpcap": *eng = EnginePcap case "pcap_file": * 阅读全文
摘要:
--input-file-dry-run: 预览时间和请求信息 --input-file-max-wait: 允许跳过已记录文件中的长暂停(s) --input-file-read-depth: 预读和缓冲请求(并排序)。缺省值是100 源码解析,plugins.go for _, options 阅读全文
摘要:
默认100毫秒刷一次盘,可以通过--output-file-flush-interval func NewFileOutput(pathTemplate string, config *FileOutputConfig) *FileOutput { o := new(FileOutput) o.pa 阅读全文
摘要:
Goreplay是一款做http请求录制回放的工具,go语言开发,基于验证在正常请求下,是否有报错;在倍数请求下,系统是否存在性能瓶颈 https://github.com/buger/goreplay/wiki 原理 - 使用pcap的go接口,使用bpf(伯克利包过滤)设置指定端口的过滤表达式, 阅读全文
摘要:
output-http-queue-len output_http.go 各种初始化 func NewHTTPOutput(address string, config *HTTPOutputConfig) PluginReadWriter { o := new(HTTPOutput) var er 阅读全文
摘要:
官文 https://github.com/buger/goreplay/wiki/Dealing-with-missing-requests-and-responses 实际操作中,发现录制流量并发达到一定量会丢失很多请求,经过阅读文档和测试,发现最相关的一个参数是 --input-raw-buf 阅读全文
摘要:
变速配置从何解析 gor.go 主方法 初始化插件,启动emiter监听 func main() { if os.Getenv("GOMAXPROCS") == "" { runtime.GOMAXPROCS(runtime.NumCPU() * 2) } args := os.Args[1:] v 阅读全文
摘要:
http_modifier.go package main import ( "bytes" "encoding/base64" "hash/fnv" "strings" "github.com/buger/goreplay/proto" ) type HTTPModifier struct { c 阅读全文
摘要:
这个类本身没太多东西,直接看, package main import ( "bufio" "compress/gzip" "errors" "fmt" "io" "log" "os" "path/filepath" "runtime/debug" "sort" "strconv" "strings 阅读全文
摘要:
http输出工作线程 NewHTTPOutput 默认情况 if config.WorkersMin <= 0 { config.WorkersMin = 1 } if config.WorkersMin > 1000 { config.WorkersMin = 1000 } if config.W 阅读全文
|