diff options
| author | Chris Lu <chris.lu@gmail.com> | 2019-02-15 00:09:19 -0800 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2019-02-15 00:09:19 -0800 |
| commit | 74fb237727267aa482ee07851f454ca03fbd1fdf (patch) | |
| tree | ca1a25621f932c46618da103f1cb6d7b95801168 /weed/server/common.go | |
| parent | a3b0e39b06dcc284ff255d9c2a3c1f55c05ad19c (diff) | |
| download | seaweedfs-74fb237727267aa482ee07851f454ca03fbd1fdf.tar.xz seaweedfs-74fb237727267aa482ee07851f454ca03fbd1fdf.zip | |
benchmark can work in secure mode
Diffstat (limited to 'weed/server/common.go')
| -rw-r--r-- | weed/server/common.go | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/weed/server/common.go b/weed/server/common.go index d88abfdc8..c9f17aa86 100644 --- a/weed/server/common.go +++ b/weed/server/common.go @@ -13,7 +13,6 @@ import ( "github.com/chrislusf/seaweedfs/weed/glog" "github.com/chrislusf/seaweedfs/weed/operation" - "github.com/chrislusf/seaweedfs/weed/security" "github.com/chrislusf/seaweedfs/weed/stats" "github.com/chrislusf/seaweedfs/weed/storage" "github.com/chrislusf/seaweedfs/weed/util" @@ -83,7 +82,6 @@ func debug(params ...interface{}) { } func submitForClientHandler(w http.ResponseWriter, r *http.Request, masterUrl string) { - jwt := security.GetJwt(r) m := make(map[string]interface{}) if r.Method != "POST" { writeJsonError(w, r, http.StatusMethodNotAllowed, errors.New("Only submit via POST!")) @@ -125,7 +123,7 @@ func submitForClientHandler(w http.ResponseWriter, r *http.Request, masterUrl st } debug("upload file to store", url) - uploadResult, err := operation.Upload(url, fname, bytes.NewReader(data), isGzipped, mimeType, pairMap, jwt) + uploadResult, err := operation.Upload(url, fname, bytes.NewReader(data), isGzipped, mimeType, pairMap, assignResult.Auth) if err != nil { writeJsonError(w, r, http.StatusInternalServerError, err) return |
