OpenTelemetry Instrumentation

Arconia OpenTelemetry supports instrumentation for Spring Boot applications in two ways:

  • Micrometer Instrumentation. Micrometer provides APIs for instrumenting Java applications, including Observation, MeterRegistry, and Tracer. Most libraries in the Spring ecosystem are already instrumented with Micrometer. Arconia OpenTelemetry includes a bridge between Micrometer and OpenTelemetry, allowing you to export metrics and traces to OpenTelemetry.

  • OpenTelemetry Java Instrumentation. OpenTelemetry provides a set of instrumentation libraries for Java applications.

You can instrument your applications either by using the Micrometer APIs or the OpenTelemetry APIs. The choice depends on your requirements and the libraries you are using.

The OpenTelemetry Java Agent is not supported by Arconia OpenTelemetry. If you’d like to continue using the Agent, check out the OpenTelemetry Buildpack for adding it to your application out-of-the-box.

Micrometer Instrumentation

Micrometer-based instrumentation is recommended by the Spring Boot project, and it can be customized via the usual Spring Boot facilities. Check out the Micrometer and Spring Boot documentation for more information.

There are three types of instrumentation you can find in the libraries from the Spring ecosystem:

  • Metrics instrumentation using the MeterRegistry API. In Arconia, such metrics are automatically bridged and exported to OpenTelemetry.

  • Traces instrumentation using the Tracer API. In Arconia, such traces are automatically bridged and exported to OpenTelemetry.

  • Unified instrumentation using the Observation API, which results in both metrics and traced being generated. In Arconia, both of them are automatically bridged and exported to OpenTelemetry.

The Observation API is the recommended way to instrument your applications, as it provides a unified way to generate observability signals and offers great flexibility since it decouples the capturing of contextual information from the actual generation of telemetry data.

Micrometer-based instrumentation follows its own semantic conventions, which have been stable for a long time and are safe to use in production. It doesn’t follow the OpenTelemetry Semantic Conventions. Work is in progress in Arconia to provide a mapping between the two sets of conventions, giving you the possibility to use the OpenTelemetry Semantic Conventions in your Micrometer-based instrumentation, should you decide to do so.

OpenTelemetry Instrumentation

The OpenTelemetry Java Instrumentation project provides a set of libraries that automatically instrument your Java applications to generate telemetry data. Arconia OpenTelemetry doesn’t use any of them by default, but it provides the necessary setup to let you easily add them to your project and use them. Check out the OpenTelemetry documentation for more information.

OpenTelemetry-based instrumentation follows the OpenTelemetry Semantic Conventions, including those that are still experimental and subject to change. Care should be taken, as they might change in a non-backward-compatible way in the future without notice. Furthermore, some instrumentation libraries might still be experimental and not yet stable, so they might change in a non-backward-compatible way in the future without notice. Always check the documentation of the specific instrumentation library you are using for more information on its stability and compatibility.