mirror of
https://gitee.com/sjqzhang/go-fastdfs.git
synced 2024-11-30 02:07:45 +08:00
when migrate file add file metadata to db
This commit is contained in:
parent
60e7f650b8
commit
7477f9ed93
@ -1203,7 +1203,9 @@ func (this *Server) DownloadFromPeer(peer string, fileInfo *FileInfo) {
|
||||
req.SetTimeout(time.Second*30, time.Second*time.Duration(timeout))
|
||||
if err = req.ToFile(fpath); err != nil {
|
||||
log.Error(err)
|
||||
return
|
||||
}
|
||||
this.SaveFileInfoToLevelDB(fileInfo.Md5, fileInfo, this.ldb)
|
||||
return
|
||||
}
|
||||
req.SetTimeout(time.Second*30, time.Second*time.Duration(timeout))
|
||||
|
Loading…
Reference in New Issue
Block a user