OpenTelemetry

OpenTelemetry is an open source, vendor neutral standard for distributed systems that are used to track the current state of the job. OpenTelemetry is a set of APIs, SDKs, tooling, and integrations designed to create and manage telemetry data such as traces and metrics.

Note: OpenTelemetry does not support checkpointing.

For more information about OpenTelemetry, see OpenTelemetry documentation.

Enabling or Disabling OpenTelemetry

OpenTelemetry can be enabled or disabled through the Monitoring UI and the BW_JAVA_OPTS environment variable.

Monitoring UI

Enable or disable OpenTelemetry.

BW_JAVA_OPTS Environment Variable

Configure the following engine property in the BW_JAVA_OPTS environment variable while running the application to enable and disable OpenTelemetry:

  • bw.engine.opentelemetry.enable=true.
    Note: By default, the property is false.

The following table describes how you can enable trace, metric, or both the variants simultaneously by setting up the BWEngine properties accordingly:

PropertiesTraceMetric
bw.engine.opentelemetry.enable=true

bw.engine.opentelemetry.trace.enable=true or blank

bw.engine.opentelemetry.metric.enable=false or blank

EnableDisable
bw.engine.opentelemetry.enable=true

bw.engine.opentelemetry.trace.enable=false

bw.engine.opentelemetry.metric.enable=true

DisableEnable
bw.engine.opentelemetry.enable=true

bw.engine.opentelemetry.trace.enable=true or blank

bw.engine.opentelemetry.metric.enable=true

EnableEnable

OpenTelemetry via OpenTelemetry-Collector

  1. Set up the OpenTelemetry-collector service. You can further integrate OpenTelemetry with a tracing service provider that is compliant with OpenTelemetry.

Note: The OpenTelemetry via OpenTelemetry-Collector is the recommended approach.

 

To configure OpenTelemetry native properties for traces, set the bw.opentelemetry.autoConfigured system property to True. Once this property is set to true, you can use the environment variables https://opentelemetry.io/docs/specs/otel/configuration/sdk-environment-variables/ listed out here.

Note: For this release, only the Span environment variable is supported.

 

To send data over the HTTP protocol for OpenTelemetry traces and metrics, set the bw.engine.opentelemetry.http.protocol system property to True.

 

To configure AWS_XRAY for OpenTelemetry traces and metrics, set the bw.engine.opentelemetry.enable, bw.opentelemetry.aws.xrayIdGenerator, and bw.engine.opentelemetry.metric.enable system property to True.

 

To enable logging for the OpenTelemetry traces and metrics, set the io.opentelemetry logger in the logback.xml file. Pass this logger as an environment variable. On enabling this logger, all the detailed information about traces and metrics is available in the logs.

Logback file example:

<logger name="io.opentelemetry">       

<level value="ALL"/>

</logger>

Container (environment variable) example:

BW_LOGGER_OVERRIDES="io.opentelemetry=ALL"

Note: The OpenTelemetry's TraceId and SpanId are available in BW logs (TIBCO Business Studio for BusinessWorks and Runtime). To get the TraceId and SpanId in the log, you must enable OpenTelemetry.

The OpenTelemetry TraceId and SpanId parameters can be mapped from an application's ProcessContext to any output activity such as Log or Write File.