diff --git a/server/transporter.go b/server/transporter.go index f50dd0b5f..95545a827 100644 --- a/server/transporter.go +++ b/server/transporter.go @@ -223,7 +223,7 @@ func (t *transporter) Get(urlStr string) (*http.Response, *http.Request, error) // Cancel the on fly HTTP transaction when timeout happens. func (t *transporter) CancelWhenTimeout(req *http.Request) { go func() { - time.Sleep(ElectionTimeout) + time.Sleep(tranTimeout) t.transport.CancelRequest(req) }() }