diff --git a/cmd/executorserver/grpc_executor/grpc.go b/cmd/executorserver/grpc_executor/grpc.go index fec3758..22fc2e3 100644 --- a/cmd/executorserver/grpc_executor/grpc.go +++ b/cmd/executorserver/grpc_executor/grpc.go @@ -58,7 +58,7 @@ func (e *execServer) Exec(ctx context.Context, req *pb.Request) (*pb.Response, e rt := <-e.worker.Submit(ctx, r) e.logger.Sugar().Debugf("response: %+v", rt) if rt.Error != nil { - return nil, err + return nil, rt.Error } return convertPBResponse(rt), nil } diff --git a/cmd/executorserver/main.go b/cmd/executorserver/main.go index 63c115d..f59134e 100644 --- a/cmd/executorserver/main.go +++ b/cmd/executorserver/main.go @@ -245,11 +245,7 @@ func newGRPCServer(conf *config.Config, esServer pb.ExecutorServer) *grpc.Server func initGinMetrics(r *gin.Engine) { p := ginprometheus.NewPrometheus("gin") p.ReqCntURLLabelMappingFn = func(c *gin.Context) string { - url := c.Request.URL.Path - for _, p := range c.Params { - url = strings.Replace(url, p.Value, ":"+p.Key, 1) - } - return url + return c.FullPath() } p.Use(r) }