beyondstorage / go-service-cos Goto Github PK
View Code? Open in Web Editor NEWTencent Cloud Object Storage (COS) support for go-storage
Home Page: https://beyondstorage.io/docs/go-storage/services/cos
Tencent Cloud Object Storage (COS) support for go-storage
Home Page: https://beyondstorage.io/docs/go-storage/services/cos
This is the service tracking issue that generated by go-community, please close with comments if not applicable to this project.
If this service has native support for Link
or Symlink
:
CreateLink
APIList
/Stat
If this service doesn't have native support for Link
or Symlink
, it's optinal to implement the virtual_link
features:
virtual_link
feature (take this issue as the tracking issue)This is the service tracking issue that generated by go-community, please close with comments if not applicable to this project.
formatError
to add new errors checkMigrate to go-storage v3.4.2.
According to COS API doc, when GetObject
with Range
header:
例如 bytes=0-9,表示下载对象的开头10个字节的数据;bytes=5-9,表示下载对象的第6到第10个字节。此时返回 HTTP 状态码206(Partial Content)及 Content-Range 响应头部。
And also, FormatRangeOptions()
was provided to format Range
value in cos-go-sdk:
func FormatRangeOptions(opt *RangeOptions) string {
if opt == nil {
return ""
}
if opt.HasStart && opt.HasEnd {
return fmt.Sprintf("bytes=%v-%v", opt.Start, opt.End)
}
if opt.HasStart {
return fmt.Sprintf("bytes=%v-", opt.Start)
}
if opt.HasEnd {
return fmt.Sprintf("bytes=-%v", opt.End)
}
return ""
}
Based on the above, we envision that when Range: bytes=-9
we should be able to download data from 0 to 9([0-9]).
RangeOptions.End
as follows, we will get the read size check error.
rangeOptions := &cos.RangeOptions{}
if opt.HasSize {
rangeOptions.HasEnd = true
rangeOptions.End = rangeOptions.Start + opt.Size - 1
}
RangeOptions.End
as follows, we will get the read content check error.
rangeOptions := &cos.RangeOptions{}
if opt.HasSize {
rangeOptions.HasEnd = true
rangeOptions.End = opt.Size
}
Run integration test after modifying the code as above.
github.com/tencentyun/cos-go-sdk-v5 v0.7.31
For CompleteMultipartUpload in cos:
InvalidPart
will be returned when this API is called.InvalidPartOrder
will be returned when this API is called.Random part number in CompletePart
test case leads to the failure of multiparter
integration test.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.