-
Notifications
You must be signed in to change notification settings - Fork 821
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Spec: SpanProcessor.onStart MUST receive a mutable "read/write" span #1620
Comments
Thanks for reporting this. The concrete span sent to onStart is already a |
Just curious to know the use-case where we need writeable span in SpanProcessor.onStart? |
One use case for SpanProcessors is to add certain attributes on a span. The thread ID (of the starting span), for example, is a property that calls for being added automatically rather than bugging users with that. The |
@mayurkale22 user @GasimGasimzada has already asked for this in gitter too |
For example, we have a tracer in the browser and for all spans we add http user agent, the current URL, and other custom attributes that are applicable to our app for all spans. In my case, I extends SimpleSpanProcessor and overrode const span = readableSpan as unknown as Span; |
… if the last layer is not REQUEST_HANDLER (open-telemetry#1620) * fix(express): make rpcMetadata.route capture the last layer even when if the last layer is mot REQUEST_HANDLER * fix lint issue * remove test.only * revert code to change ignore order * update test * remove comment related to update span name * Move rpcRoute.metadata calculation logic up * Add more test * Fix lint
See https://github.com/open-telemetry/opentelemetry-specification/blob/master/specification/trace/sdk.md#onstart
Currently only an immutable
ReadableSpan
is passed:opentelemetry-js/packages/opentelemetry-tracing/src/SpanProcessor.ts
Lines 29 to 34 in dc8082a
The text was updated successfully, but these errors were encountered: