A365SpanProcessor class
Copies relevant baggage entries to span attributes on span start.
This is the "automatic" counterpart to the manual scope API — it ensures every span in the pipeline gets agent identity attributes from baggage without explicitly creating scopes.
Methods
| force |
Force flush the processor. |
| on |
Called when a span is ended. |
| on |
Called when a span is started. Copies relevant baggage entries to span attributes. |
| shutdown() | Shutdown the processor. |
Method Details
forceFlush()
Force flush the processor.
function forceFlush(): Promise<void>
Returns
Promise<void>
onEnd(ReadableSpan)
Called when a span is ended.
function onEnd(_span: ReadableSpan)
Parameters
- _span
-
ReadableSpan
onStart(Span, Context)
Called when a span is started. Copies relevant baggage entries to span attributes.
function onStart(span: Span, parentContext?: Context)
Parameters
- span
-
Span
- parentContext
-
Context
shutdown()
Shutdown the processor.
function shutdown(): Promise<void>
Returns
Promise<void>