SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.
Go blob-storagecloud-drivedistributed-file-systemdistributed-storageerasure-codingfusehadoop-hdfshdfskuberneteslancelancedbobject-storageposixs3s3-storageseaweedfstiered-file-systemvector-search
reduced the timeout for creating a connection from 30 to 10 seconds
Konstantin Lebedevc2e7d663bcb0
diff --git a/weed/operation/upload_content.go b/weed/operation/upload_content.goindex 569a543723..3d41d2eb57 100644--- a/weed/operation/upload_content.go+++ b/weed/operation/upload_content.go@@ -11,6 +11,7 @@ import ("io""mime""mime/multipart"+ "net""net/http""net/textproto""path/filepath"@@ -65,6 +66,10 @@ var (func init() {HttpClient = &http.Client{Transport: &http.Transport{+ DialContext: (&net.Dialer{+ Timeout: 10 * time.Second,+ KeepAlive: 10 * time.Second,+ }).DialContext,MaxIdleConns: 1024,MaxIdleConnsPerHost: 1024,}}@@ -261,6 +266,7 @@ func upload_content(fillBufferFunction func(w io.Writer) error, originalDataSizeif post_err != nil {if strings.Contains(post_err.Error(), "connection reset by peer") ||strings.Contains(post_err.Error(), "use of closed network connection") {+ glog.V(1).Infof("repeat error upload request %s: %v", option.UploadUrl, postErr)resp, post_err = HttpClient.Do(req)}}