Skip to content

Commit

Permalink
object: fix the limiting interface of object storage (#5239)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhijian-pro authored and jiefenghuang committed Nov 26, 2024
1 parent 7c77b2b commit bb9ba81
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
4 changes: 3 additions & 1 deletion pkg/object/ibmcos.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,9 @@ func (s *ibmcos) Create() error {
func (s *ibmcos) Limits() Limits {
return Limits{
IsSupportMultipartUpload: true,
IsSupportUploadPartCopy: false,
MinPartSize: 5 << 20,
MaxPartSize: 5 << 30,
MaxPartCount: 10000,
}
}

Expand Down
4 changes: 3 additions & 1 deletion pkg/object/oos.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ func (s *oos) String() string {
func (s *oos) Limits() Limits {
return Limits{
IsSupportMultipartUpload: true,
IsSupportUploadPartCopy: false,
MinPartSize: 5 << 20,
MaxPartSize: 5 << 30,
MaxPartCount: 10000,
}
}

Expand Down
4 changes: 3 additions & 1 deletion pkg/object/scs.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,9 @@ func (s *scsClient) String() string {
func (s *scsClient) Limits() Limits {
return Limits{
IsSupportMultipartUpload: true,
IsSupportUploadPartCopy: false,
MinPartSize: 5 << 20,
MaxPartSize: 5 << 30, // guess
MaxPartCount: 2048,
}
}

Expand Down
5 changes: 1 addition & 4 deletions pkg/object/space.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,7 @@ func (s *space) String() string {
}

func (s *space) Limits() Limits {
return Limits{
IsSupportMultipartUpload: true,
IsSupportUploadPartCopy: false,
}
return s.s3client.Limits()
}

func newSpace(endpoint, accessKey, secretKey, token string) (ObjectStorage, error) {
Expand Down

0 comments on commit bb9ba81

Please sign in to comment.