Skip to content

Commit

Permalink
v2
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-pfus committed Dec 13, 2024
1 parent ecb5dc9 commit fd20716
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion gcs_storage_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@ package gosnowflake

import (
"context"
"crypto/tls"
"encoding/json"
"fmt"
"io"
"net"
"net/http"
"net/url"
"os"
Expand Down Expand Up @@ -401,6 +403,18 @@ func (util *snowflakeGcsClient) isTokenExpired(resp *http.Response) bool {

func newGcsClient() gcsAPI {
return &http.Client{
//Transport: SnowflakeTransport,
Transport: &http.Transport{
TLSClientConfig: &tls.Config{
RootCAs: certPool,
VerifyPeerCertificate: verifyPeerCertificateSerial,
},
MaxIdleConns: 10,
IdleConnTimeout: 30 * time.Minute,
Proxy: http.ProxyFromEnvironment,
DialContext: (&net.Dialer{
Timeout: 30 * time.Second,
KeepAlive: 30 * time.Second,
}).DialContext,
},
}
}

0 comments on commit fd20716

Please sign in to comment.