Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2c06d5299e | ||
|
|
c403391509 | ||
|
|
5172396831 |
12
CHANGELOG.md
12
CHANGELOG.md
@@ -7,6 +7,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
||||
|
||||
## [v0.7.17](https://github.com/tencentyun/cos-go-sdk-v5/compare/v0.7.16...v0.7.17) - 2020-12-29
|
||||
|
||||
add multicopy
|
||||
|
||||
### Merged
|
||||
|
||||
- add MultiCopy [`#99`](https://github.com/tencentyun/cos-go-sdk-v5/pull/99)
|
||||
|
||||
### Commits
|
||||
|
||||
- Updated CHANGELOG.md [`91fc87b`](https://github.com/tencentyun/cos-go-sdk-v5/commit/91fc87ba8af042adb0d0bf147f8fe6aa49057976)
|
||||
|
||||
## [v0.7.16](https://github.com/tencentyun/cos-go-sdk-v5/compare/v0.7.15...v0.7.16) - 2020-12-24
|
||||
|
||||
add bucket accelerate && update upload progress
|
||||
|
||||
2
cos.go
2
cos.go
@@ -22,7 +22,7 @@ import (
|
||||
|
||||
const (
|
||||
// Version current go sdk version
|
||||
Version = "0.7.17"
|
||||
Version = "0.7.18"
|
||||
userAgent = "cos-go-sdk-v5/" + Version
|
||||
contentTypeXML = "application/xml"
|
||||
defaultServiceBaseURL = "http://service.cos.myqcloud.com"
|
||||
|
||||
@@ -113,7 +113,7 @@ func decodeURIComponent(s string) (string, error) {
|
||||
}
|
||||
|
||||
func DecodeURIComponent(s string) (string, error) {
|
||||
return DecodeURIComponent(s)
|
||||
return decodeURIComponent(s)
|
||||
}
|
||||
|
||||
func EncodeURIComponent(s string) string {
|
||||
|
||||
@@ -563,12 +563,12 @@ func worker(s *ObjectService, jobs <-chan *Jobs, results chan<- *Results) {
|
||||
results <- &res
|
||||
}
|
||||
|
||||
fd.Seek(j.Chunk.OffSet, os.SEEK_SET)
|
||||
// UploadPart do not support the chunk trsf, so need to add the content-length
|
||||
j.Opt.ContentLength = int(j.Chunk.Size)
|
||||
|
||||
rt := j.RetryTimes
|
||||
for {
|
||||
fd.Seek(j.Chunk.OffSet, os.SEEK_SET)
|
||||
resp, err := s.UploadPart(context.Background(), j.Name, j.UploadId, j.Chunk.Number,
|
||||
&io.LimitedReader{R: fd, N: j.Chunk.Size}, j.Opt)
|
||||
res.PartNumber = j.Chunk.Number
|
||||
|
||||
Reference in New Issue
Block a user