We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc5ea9e commit 2657593Copy full SHA for 2657593
http/handlers.go
@@ -73,8 +73,11 @@ func (s *Server) RPCCallHandler(newClient func() Client) http.HandlerFunc {
73
returnError(w, errors.Cause(err).(perrors.Error))
74
return
75
}
76
+ // TODO: Re-Use connections instead of creating a new connection for each request.
77
client := newClient()
78
client.Connect(ctx, u)
79
+ defer client.CloseConn()
80
+
81
md := make(metadata.Metadata)
82
83
inputMessage, err := ioutil.ReadAll(r.Body)
0 commit comments