TraceProvider
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new TraceProvider(): TraceProvider
Returns
Section titled “Returns”TraceProvider
Methods
Section titled “Methods”createSpan()
Section titled “createSpan()”createSpan<TSpanData>(spanOptions, parent?): Span<TSpanData>
Type Parameters
Section titled “Type Parameters”Type Parameter |
---|
|
Parameters
Section titled “Parameters”Parameter | Type |
---|---|
|
|
|
Returns
Section titled “Returns”Span
<TSpanData
>
createTrace()
Section titled “createTrace()”createTrace(traceOptions): Trace
Parameters
Section titled “Parameters”Parameter | Type |
---|---|
|
|
Returns
Section titled “Returns”getCurrentSpan()
Section titled “getCurrentSpan()”getCurrentSpan(): null | Span<any>
Returns
Section titled “Returns”null
| Span
<any
>
getCurrentTrace()
Section titled “getCurrentTrace()”getCurrentTrace(): null | Trace
Get the current trace.
Returns
Section titled “Returns”null
| Trace
The current trace.
registerProcessor()
Section titled “registerProcessor()”registerProcessor(processor): void
Add a processor to the list of processors. Each processor will receive all traces/spans.
Parameters
Section titled “Parameters”Parameter | Type | Description |
---|---|---|
|
The processor to add. |
Returns
Section titled “Returns”void
setDisabled()
Section titled “setDisabled()”setDisabled(disabled): void
Parameters
Section titled “Parameters”Parameter | Type |
---|---|
|
|
Returns
Section titled “Returns”void
setProcessors()
Section titled “setProcessors()”setProcessors(processors): void
Set the list of processors. This will replace any existing processors.
Parameters
Section titled “Parameters”Parameter | Type | Description |
---|---|---|
|
The list of processors to set. |
Returns
Section titled “Returns”void
shutdown()
Section titled “shutdown()”shutdown(timeout?): void
Parameters
Section titled “Parameters”Parameter | Type |
---|---|
|
|
Returns
Section titled “Returns”void