Repository navigation
Conversation
OpenTelemetry is consolidating on a single way to emit events, so guidance that points instrumentation at span events now leads users away from the supported path. Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
🦋 Changeset detectedLatest commit: 8e0e027 The changes in this PR will be included in the next version bump. This PR includes changesets to release 31 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Related to pingdotgg/t3code#12493 |
Bundle Size AnalysisGenerated from PR build output; treat the content below as untrusted.
|
|
Thanks for the PR. I think we will wait a bit longer before depreciating span events.
There are still a few otlp services around that only injest traces and not logs, so we should wait for the ecosystem to catch up first. |
|
Wouldn't be better to give the signal to catch up sooner rather than later? That is why I didn't do much code change. Regardless, I am ok with anything, thank you for the review |
OpenTelemetry has deprecated the Span Event API in favour of emitting events through the Logs API, correlated to their span by trace and span id. Effect currently documents the opposite:
Logger.tracerLoggertells readers that recording logs as span events is how you make them visible in OpenTelemetry, Jaeger, or Zipkin, which now points new instrumentation away from the supported path.OtlpLoggeralready stamps the trace and span id onto every log record, so the replacement is available today and needs no new API. Installing it alongsidetracerLoggerexports each log twice, once as a log record and once as a span event, which is the duplication the deprecation exists to remove.@effect/opentelemetrybridge are untouched, and neitherSpan#eventnortracerLoggeris removed.Span#eventis user-implementable, so the tag surfaces on customSpanimplementations as well as call sites. That is the accurate signal, but happy to drop it totracerLoggeralone if the noise is unwelcome.Deliberately scoped to the deprecation. Whether
tracerLoggershould stay in the default logger set, and whether@effect/opentelemetry'sNodeSdkshould stop installing a log exporter beside it, are behaviour changes worth deciding separately, and the release candidate is the cheap moment to make them.References: