Skip to content

Commit

Permalink
⚡ when high concurrency occurs, the connection is full and the connec…
Browse files Browse the repository at this point in the history
…tion is rejected.
  • Loading branch information
cuisongliu committed May 9, 2024
1 parent 7d3be80 commit b392958
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions api/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ func (c *httpClient) Do(ctx context.Context, req *http.Request) (*http.Response,
if ctx != nil {
req = req.WithContext(ctx)
}
defer c.client.CloseIdleConnections()
resp, err := c.client.Do(req)
defer func() {
if resp != nil {
Expand Down

0 comments on commit b392958

Please sign in to comment.