For compatibility with NodeNext + esModuleInterop: false
Add tracer as a named export
Returns a SpanContext instance extracted from carrier
in the given
format
.
The format of the carrier.
The carrier object.
The extracted SpanContext, or null if no such SpanContext could
be found in carrier
Initializes the tracer. This should be called before importing other libraries.
Optional
options: TracerOptionsInjects the given SpanContext instance for cross-process propagation
within carrier
The SpanContext to inject into the carrier object. As a convenience, a Span instance may be passed in instead (in which case its .context() is used for the inject()).
The format of the carrier.
The carrier object.
Instruments a function by automatically creating a span activated on its scope.
The span will automatically be finished when one of these conditions is met:
If the orphanable
option is set to false, the function will not be traced
unless there is already an active span or childOf
option. Note that this
option is deprecated and has been removed in version 4.0.
Wrap a function to automatically create a span activated on its scope when it's called.
The span will automatically be finished when one of these conditions is met:
Rest
...args: any[]Generated using TypeDoc
Tracer is the entry-point of the Datadog tracing implementation.