migrate volume sync status to grpc API on volume server

This commit is contained in:
Chris Lu
2018-10-15 01:19:15 -07:00
parent b423bb9e2d
commit fda771c83f
10 changed files with 215 additions and 92 deletions

View File

@@ -2,11 +2,11 @@ package weed_server
import (
"fmt"
"net/http"
"path/filepath"
"github.com/chrislusf/seaweedfs/weed/stats"
"github.com/chrislusf/seaweedfs/weed/stats"
"github.com/chrislusf/seaweedfs/weed/storage"
"github.com/chrislusf/seaweedfs/weed/util"
"net/http"
"path/filepath"
)
func (vs *VolumeServer) statusHandler(w http.ResponseWriter, r *http.Request) {
@@ -29,6 +29,7 @@ func (vs *VolumeServer) statsDiskHandler(w http.ResponseWriter, r *http.Request)
writeJsonQuiet(w, r, http.StatusOK, m)
}
// TODO delete this when volume sync is all moved to grpc
func (vs *VolumeServer) getVolume(volumeParameterName string, r *http.Request) (*storage.Volume, error) {
vid, err := vs.getVolumeId(volumeParameterName, r)
if err != nil {