Skip to content

Commit

Permalink
store/helper: remove timeout for fetch diagnose from info pd (#11383)
Browse files Browse the repository at this point in the history
All tests passed, auto merged by Bot
  • Loading branch information
sre-bot authored Jul 25, 2019
1 parent f375c91 commit a79a86e
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions store/helper/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -418,9 +418,7 @@ func (h *Helper) GetRegionsInfo() (*RegionsInfo, error) {
if err != nil {
return nil, errors.Trace(err)
}
timeout, cancelFunc := context.WithTimeout(context.Background(), 5*time.Second)
resp, err := http.DefaultClient.Do(req.WithContext(timeout))
defer cancelFunc()
resp, err := http.DefaultClient.Do(req)
if err != nil {
return nil, errors.Trace(err)
}
Expand Down Expand Up @@ -497,9 +495,7 @@ func (h *Helper) GetStoresStat() (*StoresStat, error) {
if err != nil {
return nil, errors.Trace(err)
}
timeout, cancelFunc := context.WithTimeout(context.Background(), 50*time.Millisecond)
resp, err := http.DefaultClient.Do(req.WithContext(timeout))
defer cancelFunc()
resp, err := http.DefaultClient.Do(req)
if err != nil {
return nil, errors.Trace(err)
}
Expand Down

0 comments on commit a79a86e

Please sign in to comment.