diff options
| author | Chris Lu <chris.lu@gmail.com> | 2020-12-13 11:59:32 -0800 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2020-12-13 11:59:32 -0800 |
| commit | 0d2ec832e2ced90371f2c5549b175d5b93becd1a (patch) | |
| tree | 8f4fddcc88491331b0e395c1606b8cb9d6d00513 /weed/operation/submit.go | |
| parent | 715b199eeb6fbd3f028b99e42097096fdcac5e09 (diff) | |
| download | seaweedfs-0d2ec832e2ced90371f2c5549b175d5b93becd1a.tar.xz seaweedfs-0d2ec832e2ced90371f2c5549b175d5b93becd1a.zip | |
rename from volumeType to diskType
Diffstat (limited to 'weed/operation/submit.go')
| -rw-r--r-- | weed/operation/submit.go | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/weed/operation/submit.go b/weed/operation/submit.go index 70ab4194a..bcdf9ddce 100644 --- a/weed/operation/submit.go +++ b/weed/operation/submit.go @@ -25,7 +25,7 @@ type FilePart struct { Collection string DataCenter string Ttl string - VolumeType string + DiskType string Server string //this comes from assign result Fid string //this comes from assign result, but customizable Fsync bool @@ -39,7 +39,7 @@ type SubmitResult struct { Error string `json:"error,omitempty"` } -func SubmitFiles(master string, grpcDialOption grpc.DialOption, files []FilePart, replication string, collection string, dataCenter string, ttl string, volumeType string, maxMB int, usePublicUrl bool) ([]SubmitResult, error) { +func SubmitFiles(master string, grpcDialOption grpc.DialOption, files []FilePart, replication string, collection string, dataCenter string, ttl string, diskType string, maxMB int, usePublicUrl bool) ([]SubmitResult, error) { results := make([]SubmitResult, len(files)) for index, file := range files { results[index].FileName = file.FileName @@ -50,7 +50,7 @@ func SubmitFiles(master string, grpcDialOption grpc.DialOption, files []FilePart Collection: collection, DataCenter: dataCenter, Ttl: ttl, - VolumeType: volumeType, + DiskType: diskType, } ret, err := Assign(master, grpcDialOption, ar) if err != nil { @@ -72,7 +72,7 @@ func SubmitFiles(master string, grpcDialOption grpc.DialOption, files []FilePart file.Collection = collection file.DataCenter = dataCenter file.Ttl = ttl - file.VolumeType = volumeType + file.DiskType = diskType results[index].Size, err = file.Upload(maxMB, master, usePublicUrl, ret.Auth, grpcDialOption) if err != nil { results[index].Error = err.Error() @@ -146,7 +146,7 @@ func (fi FilePart) Upload(maxMB int, master string, usePublicUrl bool, jwt secur Replication: fi.Replication, Collection: fi.Collection, Ttl: fi.Ttl, - VolumeType: fi.VolumeType, + DiskType: fi.DiskType, } ret, err = Assign(master, grpcDialOption, ar) if err != nil { @@ -160,7 +160,7 @@ func (fi FilePart) Upload(maxMB int, master string, usePublicUrl bool, jwt secur Replication: fi.Replication, Collection: fi.Collection, Ttl: fi.Ttl, - VolumeType: fi.VolumeType, + DiskType: fi.DiskType, } ret, err = Assign(master, grpcDialOption, ar) if err != nil { |
