🔥 移除不必要的日志打印
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
李寻欢 2021-09-09 11:58:02 +08:00
parent feb62f12b7
commit e973fea5f3

View File

@ -3,7 +3,6 @@ package middleware
import ( import (
"fmt" "fmt"
gc "gateway/config" gc "gateway/config"
"gateway/core"
"github.com/gin-gonic/gin" "github.com/gin-gonic/gin"
"github.com/opentracing/opentracing-go" "github.com/opentracing/opentracing-go"
"github.com/opentracing/opentracing-go/ext" "github.com/opentracing/opentracing-go/ext"
@ -21,7 +20,7 @@ func OpenTracing() gin.HandlerFunc {
spCtx, err := opentracing.GlobalTracer().Extract(opentracing.HTTPHeaders, opentracing.HTTPHeadersCarrier(c.Request.Header)) spCtx, err := opentracing.GlobalTracer().Extract(opentracing.HTTPHeaders, opentracing.HTTPHeadersCarrier(c.Request.Header))
if err != nil { if err != nil {
core.Log.Error("Jaeger错误: %v", err.Error()) //core.Log.Error("Jaeger错误: %v", err.Error())
parentSpan = tracer.StartSpan(c.Request.URL.Path) parentSpan = tracer.StartSpan(c.Request.URL.Path)
defer parentSpan.Finish() defer parentSpan.Finish()
} else { } else {