OtelModule
PackageAxial.Telemetry.JavaScript
OpenTelemetry JS tracing for Axial workflows compiled with Fable: the JavaScript counterpart of the
.NET package's
Activity.trace, emitting through a host-supplied @opentelemetry/api object.
Summary
| Name | Signature | Synopsis |
|---|---|---|
| Operations | ||
| installNamed | Otel.installNamed api instrumentationScopeName | Installs a tracer under the supplied instrumentation scope name. |
| install | Otel.install api | Installs a tracer under Axial's default instrumentation scope. |
| installWith | Otel.installWith api tracer | Installs an explicit tracer, for a custom instrumentation scope name. |
| uninstall | Otel.uninstall () | Removes the installed tracer; subsequent traced flows run untraced. |
| traceWith | Otel.traceWith renderError name sourceFlow | JavaScript-only: on .NET this returns the flow unchanged. |
| trace | Otel.trace name sourceFlow | Wraps a flow in a new OpenTelemetry span covering the workflow's execution. |
Operations
kind:member
Installs a tracer under the supplied instrumentation scope name. Use the application's scope name for spans
that describe application behavior. Call once at the application edge, after the OpenTelemetry JS SDK and its
context manager are registered. JavaScript targets only.
Parameters
| Name | Type | Description |
|---|---|---|
| api | OpenTelemetryApi | The @opentelemetry/api module object. |
| instrumentationScopeName | string | The application instrumentation scope name. |
Returns
unit
kind:member
kind:member
kind:member
kind:member
JavaScript-only: on .NET this returns the flow unchanged. Use
Activity.traceWith from
Axial.Telemetry on .NET targets.
Parameters
| Name | Type | Description |
|---|---|---|
| renderError | 'error -> string | |
| name | string | |
| sourceFlow | Flow<'env, 'error, 'value> |
Returns
Flow<'env, 'error, 'value>
kind:member
Wraps a flow in a new OpenTelemetry span covering the workflow's execution. Typed errors are
rendered with their own
ToString; see traceWith for a custom renderer. JavaScript targets only.
Parameters
| Name | Type | Description |
|---|---|---|
| name | string | The span name. |
| sourceFlow | Flow<'env, 'error, 'value> | The flow to trace. |
Returns
Flow<'env, 'error, 'value>

