Skip to content

Commit

Permalink
utils: dont set http.Client timeout to a default value
Browse files Browse the repository at this point in the history
  • Loading branch information
Benbebop committed Sep 16, 2024
1 parent 67f94a8 commit 4b35ef1
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions utils/httputil/httpdriver/default.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import (
"io"
"net/http"
"net/url"
"time"
)

// DefaultClient implements Client and wraps around the stdlib Client.
Expand All @@ -19,12 +18,9 @@ func WrapClient(client http.Client) Client {
return DefaultClient(client)
}

// NewClient creates a new client around the standard library's http.Client. The
// client will have a timeout of 10 seconds.
// NewClient creates a new client around the standard library's http.Client.
func NewClient() Client {
return WrapClient(http.Client{
Timeout: 10 * time.Second,
})
return WrapClient(http.Client{})
}

func (d DefaultClient) NewRequest(ctx context.Context, method, url string) (Request, error) {
Expand Down

0 comments on commit 4b35ef1

Please sign in to comment.