mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-12-17 09:42:29 +08:00
adjust logs
This commit is contained in:
@@ -83,7 +83,7 @@ func doList(filerClient FilerClient, fullDirPath util.FullPath, prefix string, f
|
||||
InclusiveStartFrom: inclusive,
|
||||
}
|
||||
|
||||
glog.V(4).Infof("read directory: %v", request)
|
||||
glog.V(5).Infof("read directory: %v", request)
|
||||
ctx, cancel := context.WithCancel(context.Background())
|
||||
stream, err := client.ListEntries(ctx, request)
|
||||
if err != nil {
|
||||
|
||||
@@ -10,7 +10,7 @@ import (
|
||||
"github.com/chrislusf/seaweedfs/weed/storage/needle"
|
||||
)
|
||||
|
||||
func toFileIdObject(fileIdStr string) (*FileId, error) {
|
||||
func ToFileIdObject(fileIdStr string) (*FileId, error) {
|
||||
t, err := needle.ParseFileIdFromString(fileIdStr)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
@@ -43,14 +43,14 @@ func BeforeEntrySerialization(chunks []*FileChunk) {
|
||||
for _, chunk := range chunks {
|
||||
|
||||
if chunk.FileId != "" {
|
||||
if fid, err := toFileIdObject(chunk.FileId); err == nil {
|
||||
if fid, err := ToFileIdObject(chunk.FileId); err == nil {
|
||||
chunk.Fid = fid
|
||||
chunk.FileId = ""
|
||||
}
|
||||
}
|
||||
|
||||
if chunk.SourceFileId != "" {
|
||||
if fid, err := toFileIdObject(chunk.SourceFileId); err == nil {
|
||||
if fid, err := ToFileIdObject(chunk.SourceFileId); err == nil {
|
||||
chunk.SourceFid = fid
|
||||
chunk.SourceFileId = ""
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@ import (
|
||||
func TestFileIdSize(t *testing.T) {
|
||||
fileIdStr := "11745,0293434534cbb9892b"
|
||||
|
||||
fid, _ := toFileIdObject(fileIdStr)
|
||||
fid, _ := ToFileIdObject(fileIdStr)
|
||||
bytes, _ := proto.Marshal(fid)
|
||||
|
||||
println(len(fileIdStr))
|
||||
|
||||
Reference in New Issue
Block a user