mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-10-25 22:40:44 +01:00
fix compilation error, upgrade dependencies via glide
This commit is contained in:
1 parent
044de8e6a0
commit
55a685b1c3
8 files changed
+39
-31
No files matched your search
@@ -74,7 +74,7 @@ func writeJsonError(w http.ResponseWriter, r *http.Request, httpStatus int, err
|
||||
}
|
||||
|
||||
func debug(params ...interface{}) {
|
||||
glog.V(4).Infoln(params)
|
||||
glog.V(4).Infoln(params...)
|
||||
}
|
||||
|
||||
func submitForClientHandler(w http.ResponseWriter, r *http.Request, masterUrl string) {
|
||||
|
||||
@@ -101,7 +101,7 @@ func (fs *FilerServer) GetOrHeadHandler(w http.ResponseWriter, r *http.Request,
|
||||
|
||||
urlLocation, err := operation.LookupFileId(fs.getMasterNode(), fileId)
|
||||
if err != nil {
|
||||
glog.V(1).Infoln("operation LookupFileId %s failed, err is %s", fileId, err.Error())
|
||||
glog.V(1).Infof("operation LookupFileId %s failed, err:%v", fileId, err)
|
||||
w.WriteHeader(http.StatusNotFound)
|
||||
return
|
||||
}
|
||||
|
||||
@@ -79,7 +79,7 @@ func (fs *FilerServer) queryFileInfoByPath(w http.ResponseWriter, r *http.Reques
|
||||
} else if fileId != "" && err == nil {
|
||||
urlLocation, err = operation.LookupFileId(fs.getMasterNode(), fileId)
|
||||
if err != nil {
|
||||
glog.V(1).Infoln("operation LookupFileId %s failed, err is %s", fileId, err.Error())
|
||||
glog.V(1).Infof("operation LookupFileId %s failed, err:%s", fileId, err)
|
||||
w.WriteHeader(http.StatusNotFound)
|
||||
}
|
||||
} else if fileId == "" && err == filer.ErrNotFound {
|
||||
@@ -193,7 +193,7 @@ func (fs *FilerServer) monolithicUploadAnalyzer(w http.ResponseWriter, r *http.R
|
||||
*/
|
||||
lastPos := strings.LastIndex(r.URL.Path, "/")
|
||||
if lastPos == -1 || lastPos == 0 || lastPos == len(r.URL.Path)-1 {
|
||||
glog.V(0).Infoln("URL Path [%s] is invalid, could not retrieve file name", r.URL.Path)
|
||||
glog.V(0).Infof("URL Path [%s] is invalid, could not retrieve file name", r.URL.Path)
|
||||
err = fmt.Errorf("URL Path is invalid")
|
||||
writeJsonError(w, r, http.StatusInternalServerError, err)
|
||||
return
|
||||
|
||||
@@ -25,7 +25,7 @@ func (vs *VolumeServer) assignVolumeHandler(w http.ResponseWriter, r *http.Reque
|
||||
if r.FormValue("preallocate") != "" {
|
||||
preallocate, err = strconv.ParseInt(r.FormValue("preallocate"), 10, 64)
|
||||
if err != nil {
|
||||
glog.V(0).Infoln("ignoring invalid int64 value for preallocate = %v", r.FormValue("preallocate"))
|
||||
glog.V(0).Infof("ignoring invalid int64 value for preallocate = %v", r.FormValue("preallocate"))
|
||||
}
|
||||
}
|
||||
err = vs.store.AddVolume(
|
||||
@@ -41,7 +41,7 @@ func (vs *VolumeServer) assignVolumeHandler(w http.ResponseWriter, r *http.Reque
|
||||
} else {
|
||||
writeJsonError(w, r, http.StatusNotAcceptable, err)
|
||||
}
|
||||
glog.V(2).Infoln("assign volume = %s, collection = %s , replication = %s, error = %v",
|
||||
glog.V(2).Infof("assign volume = %s, collection = %s , replication = %s, error = %v",
|
||||
r.FormValue("volume"), r.FormValue("collection"), r.FormValue("replication"), err)
|
||||
}
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ func (vs *VolumeServer) vacuumVolumeCompactHandler(w http.ResponseWriter, r *htt
|
||||
if r.FormValue("preallocate") != "" {
|
||||
preallocate, err = strconv.ParseInt(r.FormValue("preallocate"), 10, 64)
|
||||
if err != nil {
|
||||
glog.V(0).Infoln("Failed to parse int64 preallocate = %s: %v", r.FormValue("preallocate"), err)
|
||||
glog.V(0).Infof("Failed to parse int64 preallocate = %s: %v", r.FormValue("preallocate"), err)
|
||||
}
|
||||
}
|
||||
err = vs.store.CompactVolume(r.FormValue("volume"), preallocate)
|
||||
|
||||
Reference in new issue
Block a user