Skip to content

Commit

Permalink
调整:日志显示
Browse files Browse the repository at this point in the history
  • Loading branch information
steden committed Oct 26, 2023
1 parent 2a61e96 commit ce4c078
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions trackContext.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,9 @@ func (receiver *TraceContext) printLog() {
}
switch receiver.TraceType {
case eumTraceType.WebApi:
flog.Printf("【链路追踪】TraceId:%s,耗时:%s,%s:\n%s\n", flog.Green(parse.ToString(receiver.TraceId)), flog.Red(receiver.UseTs.String()), receiver.Web.Path, strings.Join(lst.ToArray(), "\n"))
flog.Printf("【%s链路追踪】TraceId:%s,耗时:%s,%s:\n%s\n", receiver.TraceType.ToString(), flog.Green(parse.ToString(receiver.TraceId)), flog.Red(receiver.UseTs.String()), receiver.Web.Path, strings.Join(lst.ToArray(), "\n"))
default:
flog.Printf("【链路追踪】TraceId:%s,耗时:%s,%s\n%s\n", flog.Green(parse.ToString(receiver.TraceId)), flog.Red(receiver.UseTs.String()), receiver.TraceType.ToString(), strings.Join(lst.ToArray(), "\n"))
flog.Printf("【%s链路追踪】TraceId:%s,耗时:%s:\n%s\n", receiver.TraceType.ToString(), flog.Green(parse.ToString(receiver.TraceId)), flog.Red(receiver.UseTs.String()), strings.Join(lst.ToArray(), "\n"))
}

fmt.Println("-----------------------------------------------------------------")
Expand Down

0 comments on commit ce4c078

Please sign in to comment.