kitex-contrib / obs-opentelemetry

An extension library of OpenTelemetry for Kitex
Apache License 2.0
24 stars 21 forks source link

fix:fix logrus cancel trace info #33

Closed ViolaPioggia closed 12 months ago

ViolaPioggia commented 12 months ago

fix:fix logrus cancel trace info

修复了 logrus ctx 中无 trace 信息却打印出了空值的问题

以下是前后对比

image

bytedance-oss-robot[bot] commented 12 months ago

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: ViolaPioggia To complete the pull request process, please assign coderpoet after the PR has been reviewed. You can assign the PR to them by writing /assign @coderpoet in a comment when ready.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files: - **[OWNERS](https://github.com/kitex-contrib/obs-opentelemetry/blob/fix/logrus/OWNERS)** Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
CoderPoet commented 10 months ago

@ViolaPioggia @li-jin-gou 有一个更合适的修复方案哈: https://github.com/kitex-contrib/obs-opentelemetry/pull/39

nonRecord 的 span,只是表示这个 span 不可变了,并非是取不到 span context 的 noopSpan 才是取不到 span context 的

88i7SNC9Uo