swift-distributed-tracing icon indicating copy to clipboard operation
swift-distributed-tracing copied to clipboard

Task local tracer

Open czechboy0 opened this issue 9 months ago • 1 comments

Like https://github.com/apple/swift-log/issues/315, but for the tracer itself.

Would make testing easier.

czechboy0 avatar Mar 15 '25 07:03 czechboy0

As discussed before, this can be done with a backend that uses a task local so you can choose to use this imho. A test would use such system and then override the task local in every test it wants to. I’m not so sure with by default doing another task local lookup for the tracer to then look for the context, but we could benchmark and have that tradeoff discussion

ktoso avatar Jul 13 '25 02:07 ktoso