refactor(supplier): 移除苹果卡密请求中的 OpenTelemetry 传输设置
- 注释掉了设置 OpenTelemetry 传输的代码行 - 保留了请求的其他配置和逻辑
This commit is contained in:
@@ -16,13 +16,11 @@ import (
|
||||
"gateway/internal/service"
|
||||
"gateway/internal/service/supplier"
|
||||
"gateway/internal/utils"
|
||||
"net/http"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/beego/beego/v2/client/httplib"
|
||||
"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
|
||||
"go.opentelemetry.io/otel/attribute"
|
||||
"go.opentelemetry.io/otel/trace"
|
||||
"go.uber.org/zap"
|
||||
@@ -95,7 +93,7 @@ func (c *AppleCardImpl) SendCard(ctx context.Context, jsonStr string, cardInfo s
|
||||
return false, "获取苹果卡密地址失败!"
|
||||
}
|
||||
req := httplib.NewBeegoRequestWithCtx(ctx, url, "POST")
|
||||
req.SetTransport(otelhttp.NewTransport(http.DefaultTransport))
|
||||
//req.SetTransport(otelhttp.NewTransport(http.DefaultTransport))
|
||||
req.SetTimeout(time.Second*30, time.Second*30)
|
||||
req.Retries(3)
|
||||
marshal, err := json.Marshal(params)
|
||||
|
||||
Reference in New Issue
Block a user