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
go fmt
Chris Lu7ad5a901273d
diff --git a/weed/command/filer_export.go b/weed/command/filer_export.goindex 6ca360b44a..d57acedc3c 100644--- a/weed/command/filer_export.go+++ b/weed/command/filer_export.go@@ -1,10 +1,10 @@package commandimport (- "github.com/chrislusf/seaweedfs/weed/server"- "github.com/spf13/viper""github.com/chrislusf/seaweedfs/weed/filer2""github.com/chrislusf/seaweedfs/weed/glog"+ "github.com/chrislusf/seaweedfs/weed/server"+ "github.com/spf13/viper")func init() {diff --git a/weed/s3api/chunked_reader_v4.go b/weed/s3api/chunked_reader_v4.goindex 35a97dffee..061fd4a92e 100644--- a/weed/s3api/chunked_reader_v4.go+++ b/weed/s3api/chunked_reader_v4.go@@ -22,9 +22,9 @@ import ("bufio""bytes""errors"+ "github.com/dustin/go-humanize""io""net/http"- "github.com/dustin/go-humanize")// Streaming AWS Signature Version '4' constants.@@ -43,7 +43,7 @@ var errMalformedEncoding = errors.New("malformed chunked encoding")// newSignV4ChunkedReader returns a new s3ChunkedReader that translates the data read from r// out of HTTP "chunked" format before returning it.// The s3ChunkedReader returns io.EOF when the final 0-length chunk is read.-func newSignV4ChunkedReader(req *http.Request) (io.ReadCloser) {+func newSignV4ChunkedReader(req *http.Request) io.ReadCloser {return &s3ChunkedReader{reader: bufio.NewReader(req.Body),state: readChunkHeader,diff --git a/weed/s3api/filer_util.go b/weed/s3api/filer_util.goindex 67ce88a526..be807fb825 100644--- a/weed/s3api/filer_util.go+++ b/weed/s3api/filer_util.go@@ -1,12 +1,13 @@package s3apiimport (- "github.com/chrislusf/seaweedfs/weed/pb/filer_pb"- "time"- "os"- "fmt"- "github.com/chrislusf/glog""context"+ "fmt"+ "os"+ "time"++ "github.com/chrislusf/seaweedfs/weed/glog"+ "github.com/chrislusf/seaweedfs/weed/pb/filer_pb")func (s3a *S3ApiServer) mkdir(parentDirectoryPath string, dirName string) error {diff --git a/weed/s3api/s3api_auth.go b/weed/s3api/s3api_auth.goindex f429ad28d4..b680fe1e1e 100644--- a/weed/s3api/s3api_auth.go+++ b/weed/s3api/s3api_auth.go@@ -7,8 +7,8 @@ import (// AWS Signature Version '4' constants.const (- signV4Algorithm = "AWS4-HMAC-SHA256"- signV2Algorithm = "AWS"+ signV4Algorithm = "AWS4-HMAC-SHA256"+ signV2Algorithm = "AWS")// Verify if request has JWT.diff --git a/weed/s3api/s3api_object_handlers.go b/weed/s3api/s3api_object_handlers.goindex bd41a48fe4..912b76230a 100644--- a/weed/s3api/s3api_object_handlers.go+++ b/weed/s3api/s3api_object_handlers.go@@ -43,7 +43,7 @@ func (s3a *S3ApiServer) PutObjectHandler(w http.ResponseWriter, r *http.Request)rAuthType := getRequestAuthType(r)dataReader := r.Body- if rAuthType == authTypeStreamingSigned{+ if rAuthType == authTypeStreamingSigned {dataReader = newSignV4ChunkedReader(r)}