Groups
Sign in
Groups
Golang-China
Conversations
About
Send feedback
Help
Go http.Client全局初始化一次会偶发性的EOF报错
158 views
Skip to first unread message
micheal zhang
unread,
Nov 11, 2021, 9:16:34 PM
11/11/21
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Golang-China
使用了默认的长连接,但是发现会偶发性的 go 调用其他 go 模块的时候出现EOF报错,请教一下大家有没有什么好的建议
type Backend struct {
HTTPClient *http.Client
}
var B = &Backend{HTTPClient: &http.Client{Timeout: 60 * time.Second}}
Reply all
Reply to author
Forward
0 new messages