Skip to content

Commit

Permalink
调整链路实现
Browse files Browse the repository at this point in the history
  • Loading branch information
steden committed Nov 30, 2024
1 parent c8cf1e6 commit fc7f214
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions http/httpRequest.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,12 @@ func tryRequestProxy(methodName string, requestUrl string, head map[string]any,
}

// 链路追踪
if traceContext := container.Resolve[trace.IManager]().GetCurTrace(); traceContext != nil {
if traceContext := trace.CurTraceContext.Get(); traceContext != nil {
if head == nil {
head = make(map[string]any)
}
head["Trace-Id"] = traceContext.GetTraceId()
head["Trace-Level"] = traceContext.GetTraceLevel()
head["Trace-Id"] = traceContext.TraceId
head["Trace-Level"] = traceContext.TraceLevel
head["Trace-App-Name"] = core.AppName
head["Accept-Encoding"] = ""
}
Expand Down

0 comments on commit fc7f214

Please sign in to comment.