hystrix-go:使用hystrix-go的示例项目

时间:2021-06-07 15:53:17
【文件属性】:
文件名称:hystrix-go:使用hystrix-go的示例项目
文件大小:4KB
文件格式:ZIP
更新时间:2021-06-07 15:53:17
Go hystrix-go 这是使用示例项目。 该存储库还包括主进程尝试发送请求的子系统。 因此,您可以手动尝试其功能。 安装 要使用 hystrix-go, $ go get github.com/afex/hystrix-go/hystrix 用法 要运行 main(使用 hystrix 断路器), $ go run main.go 要运行子系统,需要时间来响应, $ cd sub $ go run main.go 要访问主系统, $ for i in $( seq 5 ) ; do curl -x ' ' localhost:8080 &; done 断路器将在一定数量的请求 ( RequestVolumeThreshold ) 和错误率更高的 atn 阈值 ( ErrorPercentThreshold ) 后ErrorPercentThreshold 。 打开时,所有请
【文件预览】:
hystrix-go-master
----main.go(2KB)
----sub()
--------main.go(789B)
----LICENSE(1KB)
----README.md(2KB)
----main_without_hystrix.go(1015B)

网友评论