Skip to content

Commit

Permalink
添加链路明细的注释字段
Browse files Browse the repository at this point in the history
  • Loading branch information
steden committed Jan 18, 2024
1 parent d46fd23 commit eb4b542
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions traceManager.go
Original file line number Diff line number Diff line change
Expand Up @@ -347,6 +347,7 @@ func newTraceDetail(callType eumCallType.Enum, methodName string) trace.BaseTrac
CallType: callType,
StartTs: time.Now().UnixMicro(),
EndTs: time.Now().UnixMicro(),
Comment: trace.GetComment(),
}
// 加入到当前层级列表
trace.ScopeLevel.Set(append(lstScope, baseTraceDetail))
Expand All @@ -365,8 +366,6 @@ func add(traceDetail trace.ITraceDetail) {
detail.UnTraceTs = time.Duration(detail.StartTs-t.GetStartTs()) * time.Microsecond
}
detail.TraceId, detail.AppName, detail.AppId, detail.AppIp, detail.ParentAppName = t.GetAppInfo()

detail.Comment = trace.DetailComment.Get()
t.AddDetail(traceDetail)
}
}

0 comments on commit eb4b542

Please sign in to comment.