diff options
| author | Chris Lu <chris.lu@gmail.com> | 2021-09-01 02:45:42 -0700 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2021-09-01 02:45:42 -0700 |
| commit | 7ce97b59d828b3f6d7bcdab323209740280da3f3 (patch) | |
| tree | b4f50634e183c2bc8ba897baefbf3d62731bf9f8 /weed/remote_storage | |
| parent | d1a4e19a3f0aeaabcf87aba3c99880f82bde87a3 (diff) | |
| download | seaweedfs-7ce97b59d828b3f6d7bcdab323209740280da3f3.tar.xz seaweedfs-7ce97b59d828b3f6d7bcdab323209740280da3f3.zip | |
go fmt
Diffstat (limited to 'weed/remote_storage')
| -rw-r--r-- | weed/remote_storage/gcs/gcs_storage_client.go | 6 | ||||
| -rw-r--r-- | weed/remote_storage/s3/aliyun.go | 6 | ||||
| -rw-r--r-- | weed/remote_storage/s3/backblaze.go | 6 | ||||
| -rw-r--r-- | weed/remote_storage/s3/baidu.go | 6 | ||||
| -rw-r--r-- | weed/remote_storage/s3/filebase.go | 6 | ||||
| -rw-r--r-- | weed/remote_storage/s3/storj.go | 6 | ||||
| -rw-r--r-- | weed/remote_storage/s3/tencent.go | 6 | ||||
| -rw-r--r-- | weed/remote_storage/traverse_bfs.go | 2 |
8 files changed, 22 insertions, 22 deletions
diff --git a/weed/remote_storage/gcs/gcs_storage_client.go b/weed/remote_storage/gcs/gcs_storage_client.go index 683b90086..997bf2c20 100644 --- a/weed/remote_storage/gcs/gcs_storage_client.go +++ b/weed/remote_storage/gcs/gcs_storage_client.go @@ -53,8 +53,8 @@ func (s gcsRemoteStorageMaker) Make(conf *remote_pb.RemoteConf) (remote_storage. } type gcsRemoteStorageClient struct { - conf *remote_pb.RemoteConf - client *storage.Client + conf *remote_pb.RemoteConf + client *storage.Client } var _ = remote_storage.RemoteStorageClient(&gcsRemoteStorageClient{}) @@ -169,7 +169,7 @@ func (gcs *gcsRemoteStorageClient) UpdateFileMetadata(loc *remote_pb.RemoteStora if len(metadata) > 0 { _, err = gcs.client.Bucket(loc.Bucket).Object(key).Update(context.Background(), storage.ObjectAttrsToUpdate{ - Metadata: metadata, + Metadata: metadata, }) } else { // no way to delete the metadata yet diff --git a/weed/remote_storage/s3/aliyun.go b/weed/remote_storage/s3/aliyun.go index 567c74299..864e4d5d0 100644 --- a/weed/remote_storage/s3/aliyun.go +++ b/weed/remote_storage/s3/aliyun.go @@ -30,9 +30,9 @@ func (s AliyunRemoteStorageMaker) Make(conf *remote_pb.RemoteConf) (remote_stora secretKey := util.Nvl(conf.AliyunSecretKey, os.Getenv("ALICLOUD_ACCESS_KEY_SECRET")) config := &aws.Config{ - Endpoint: aws.String(conf.AliyunEndpoint), - Region: aws.String(conf.AliyunRegion), - S3ForcePathStyle: aws.Bool(false), + Endpoint: aws.String(conf.AliyunEndpoint), + Region: aws.String(conf.AliyunRegion), + S3ForcePathStyle: aws.Bool(false), S3DisableContentMD5Validation: aws.Bool(true), } if accessKey != "" && secretKey != "" { diff --git a/weed/remote_storage/s3/backblaze.go b/weed/remote_storage/s3/backblaze.go index 914f0ca44..ca24e85d2 100644 --- a/weed/remote_storage/s3/backblaze.go +++ b/weed/remote_storage/s3/backblaze.go @@ -25,9 +25,9 @@ func (s BackBlazeRemoteStorageMaker) Make(conf *remote_pb.RemoteConf) (remote_st conf: conf, } config := &aws.Config{ - Endpoint: aws.String(conf.BackblazeEndpoint), - Region: aws.String("us-west-002"), - S3ForcePathStyle: aws.Bool(true), + Endpoint: aws.String(conf.BackblazeEndpoint), + Region: aws.String("us-west-002"), + S3ForcePathStyle: aws.Bool(true), S3DisableContentMD5Validation: aws.Bool(true), } if conf.BackblazeKeyId != "" && conf.BackblazeApplicationKey != "" { diff --git a/weed/remote_storage/s3/baidu.go b/weed/remote_storage/s3/baidu.go index dfcf32512..6021c9330 100644 --- a/weed/remote_storage/s3/baidu.go +++ b/weed/remote_storage/s3/baidu.go @@ -30,9 +30,9 @@ func (s BaiduRemoteStorageMaker) Make(conf *remote_pb.RemoteConf) (remote_storag secretKey := util.Nvl(conf.BaiduSecretKey, os.Getenv("BDCLOUD_SECRET_KEY")) config := &aws.Config{ - Endpoint: aws.String(conf.BaiduEndpoint), - Region: aws.String(conf.BaiduRegion), - S3ForcePathStyle: aws.Bool(true), + Endpoint: aws.String(conf.BaiduEndpoint), + Region: aws.String(conf.BaiduRegion), + S3ForcePathStyle: aws.Bool(true), S3DisableContentMD5Validation: aws.Bool(true), } if accessKey != "" && secretKey != "" { diff --git a/weed/remote_storage/s3/filebase.go b/weed/remote_storage/s3/filebase.go index e52c0be6e..fd5200f1a 100644 --- a/weed/remote_storage/s3/filebase.go +++ b/weed/remote_storage/s3/filebase.go @@ -31,9 +31,9 @@ func (s FilebaseRemoteStorageMaker) Make(conf *remote_pb.RemoteConf) (remote_sto secretKey := util.Nvl(conf.FilebaseSecretKey, os.Getenv("AWS_SECRET_ACCESS_KEY")) config := &aws.Config{ - Endpoint: aws.String(conf.FilebaseEndpoint), - Region: aws.String("us-east-1"), - S3ForcePathStyle: aws.Bool(true), + Endpoint: aws.String(conf.FilebaseEndpoint), + Region: aws.String("us-east-1"), + S3ForcePathStyle: aws.Bool(true), S3DisableContentMD5Validation: aws.Bool(true), } if accessKey != "" && secretKey != "" { diff --git a/weed/remote_storage/s3/storj.go b/weed/remote_storage/s3/storj.go index 058009729..9e902515a 100644 --- a/weed/remote_storage/s3/storj.go +++ b/weed/remote_storage/s3/storj.go @@ -30,9 +30,9 @@ func (s StorjRemoteStorageMaker) Make(conf *remote_pb.RemoteConf) (remote_storag secretKey := util.Nvl(conf.StorjSecretKey, os.Getenv("AWS_SECRET_ACCESS_KEY")) config := &aws.Config{ - Endpoint: aws.String(conf.StorjEndpoint), - Region: aws.String("us-west-2"), - S3ForcePathStyle: aws.Bool(true), + Endpoint: aws.String(conf.StorjEndpoint), + Region: aws.String("us-west-2"), + S3ForcePathStyle: aws.Bool(true), S3DisableContentMD5Validation: aws.Bool(true), } if accessKey != "" && secretKey != "" { diff --git a/weed/remote_storage/s3/tencent.go b/weed/remote_storage/s3/tencent.go index 9df72a7e2..b7711b956 100644 --- a/weed/remote_storage/s3/tencent.go +++ b/weed/remote_storage/s3/tencent.go @@ -30,9 +30,9 @@ func (s TencentRemoteStorageMaker) Make(conf *remote_pb.RemoteConf) (remote_stor secretKey := util.Nvl(conf.TencentSecretKey, os.Getenv("COS_SECRETKEY")) config := &aws.Config{ - Endpoint: aws.String(conf.TencentEndpoint), - Region: aws.String("us-west-2"), - S3ForcePathStyle: aws.Bool(true), + Endpoint: aws.String(conf.TencentEndpoint), + Region: aws.String("us-west-2"), + S3ForcePathStyle: aws.Bool(true), S3DisableContentMD5Validation: aws.Bool(true), } if accessKey != "" && secretKey != "" { diff --git a/weed/remote_storage/traverse_bfs.go b/weed/remote_storage/traverse_bfs.go index 4056f8715..a73a1d5fd 100644 --- a/weed/remote_storage/traverse_bfs.go +++ b/weed/remote_storage/traverse_bfs.go @@ -45,7 +45,7 @@ func TraverseBfs(listDirFn ListDirectoryFunc, parentPath util.FullPath, visitFn } -func processOneDirectory(listDirFn ListDirectoryFunc, parentPath util.FullPath, visitFn VisitFunc, dirQueue *util.Queue, dirQueueWg *sync.WaitGroup) (error) { +func processOneDirectory(listDirFn ListDirectoryFunc, parentPath util.FullPath, visitFn VisitFunc, dirQueue *util.Queue, dirQueueWg *sync.WaitGroup) error { return listDirFn(parentPath, func(dir string, name string, isDirectory bool, remoteEntry *filer_pb.RemoteEntry) error { if err := visitFn(dir, name, isDirectory, remoteEntry); err != nil { |
