Skip to content

Commit

Permalink
fix two minor issues (#799)
Browse files Browse the repository at this point in the history
  • Loading branch information
localvar authored Sep 21, 2022
1 parent e7d68e6 commit d207f05
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ build/cache
build/bin

easegress.pid
running_objects.json
running_objects*.json

*.exe

Expand Down
6 changes: 3 additions & 3 deletions pkg/object/httpserver/mux.go
Original file line number Diff line number Diff line change
Expand Up @@ -487,18 +487,18 @@ func (mi *muxInstance) serveHTTP(stdw http.ResponseWriter, stdr *http.Request) {

route := mi.search(req)
if route.code != 0 {
logger.Debugf("%s: status code of result route for [%s %s]: %d", mi.superSpec.Name(), req.Method, req.RequestURI, route.code)
logger.Debugf("%s: status code of result route for [%s %s]: %d", mi.superSpec.Name(), req.Method(), req.RequestURI, route.code)
buildFailureResponse(ctx, route.code)
return
}

handler, ok := mi.muxMapper.GetHandler(route.path.backend)
if !ok {
logger.Debugf("%s: backend(Pipeline) %q for [%s %s] not found", mi.superSpec.Name(), req.Method, req.RequestURI, route.path.backend)
logger.Debugf("%s: backend(Pipeline) %q for [%s %s] not found", mi.superSpec.Name(), req.Method(), req.RequestURI, route.path.backend)
buildFailureResponse(ctx, http.StatusServiceUnavailable)
return
}
logger.Debugf("%s: the matched backend(Pipeline) for [%s %s] is %q", mi.superSpec.Name(), req.Method, req.RequestURI, route.path.backend)
logger.Debugf("%s: the matched backend(Pipeline) for [%s %s] is %q", mi.superSpec.Name(), req.Method(), req.RequestURI, route.path.backend)

route.path.rewrite(req)
if mi.spec.XForwardedFor {
Expand Down

0 comments on commit d207f05

Please sign in to comment.