Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions util/get_cos_object.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package util
import (
"context"
"fmt"
logger "github.com/sirupsen/logrus"
"github.com/tencentyun/cos-go-sdk-v5"
"net/url"
"runtime"
Expand Down Expand Up @@ -257,12 +256,12 @@ func CheckDeleteMarkerExist(c *cos.Client, cosUrl StorageUrl, versionId string)
}

func getCosObjectList(c *cos.Client, cosUrl StorageUrl, chObjects chan<- objectInfoType, chError chan<- error, fo *FileOperations, scanSizeNum bool, withFinishSignal bool) {
startTime := time.Now().UnixNano() / 1000 / 1000
defer func() {
endTime := time.Now().UnixNano() / 1000 / 1000
costTime := int(endTime - startTime)
logger.Info(fmt.Sprintf("get cos list cost %ds", costTime/1000))
}()
//startTime := time.Now().UnixNano() / 1000 / 1000
//defer func() {
// endTime := time.Now().UnixNano() / 1000 / 1000
// costTime := int(endTime - startTime)
// logger.Info(fmt.Sprintf("get cos list cost %ds", costTime/1000))
//}()
if chObjects != nil {
defer close(chObjects)
}
Expand Down