TheThingsNetwork / lorawan-stack

The Things Stack, an Open Source LoRaWAN Network Server
https://www.thethingsindustries.com/stack/
Apache License 2.0
964 stars 303 forks source link

Harmonize tracing library usages #6277

Open adriansmares opened 1 year ago

adriansmares commented 1 year ago

Summary

We currently trace sections using both runtime/trace and OTEL tracing. We should harmonize this towards OTEL tracing, which is a super set of runtime/trace.

Current Situation

We currently use runtime/trace in most places, except the Identity Server bunstore.

Why do we need this? Who uses it, and when?

In order to harmonize racing towards OpenTelemetry.

Proposed Implementation

Use tracer.StartFromContext instead of trace.StartRegion, and consider adding attributes.

Contributing

Code of Conduct

KrishnaIyer commented 1 year ago

Nice. I'll pick this up since this was triggered from one of my PRs.