diff --git a/modules/ROOT/pages/microprofile-telemetry.adoc b/modules/ROOT/pages/microprofile-telemetry.adoc index bd0cebd30a..8f003f0cd0 100644 --- a/modules/ROOT/pages/microprofile-telemetry.adoc +++ b/modules/ROOT/pages/microprofile-telemetry.adoc @@ -20,18 +20,24 @@ link:https://projects.eclipse.org/projects/technology.microprofile/releases/micr MicroProfile Telemetry replaces MicroProfile OpenTracing. For information about migrating your applications from MicroProfile OpenTracing to MicroProfile Telemetry, see xref:reference:diff/mp-50-60-diff.adoc#telemetry[Differences between MicroProfile Telemetry 1.0 and MicroProfile OpenTracing 3.0]. +- <<#ol-config, Configuring Open Liberty to use MicroProfile Telemetry>> +- <<#code, Code instrumentation>> +- <<#trouble, Troubleshooting MicroProfile Telemetry>> + [#ol-config] == Configuring Open Liberty to use MicroProfile Telemetry To enable MicroProfile Telemetry in your Open Liberty runtime, you must add the MicroProfile Telemetry feature to your `server.xml` file and specify MicroProfile Config properties to configure how MicroProfile Telemetry collects and exports traces. . Add a version of the feature:mpTelemetry[display=MicroProfile Telemetry] feature to your `server.xml` file. +//// + Different versions of the MicroProfile Telemetry feature are compatible with different MicroProfile versions, Jakarta and Java Enterprise Editions, and the Open Liberty umbrella features that support them. Both feature:mpTelemetry-1.0[] and feature:mpTelemetry-1.1[] are compatible with feature:jakartaee-10.0[] and feature:microProfile-6.0[]. However, `mpTelemetry-1.1` is also compatible with the following earlier umbrella features: + * feature:javaee-7.0[] and feature:microProfile-1.4[] * feature:jakartaee-8.0[] and feature:microProfile-4.1[] * feature:jakartaee-9.1[] and feature:microProfile-5.0[] +//// . Enable tracing and configure a trace storage system by specifying MicroProfile Config properties. + @@ -74,6 +80,7 @@ For more information about the available properties, see xref:microprofile-confi + For more information, see the following section. +[#code] == Code instrumentation After you enable MicroProfile Telemetry and configure a trace server, you can instrument tracing in your application code by using one of the following methods: @@ -118,7 +125,7 @@ Automatic instrumentation is available only for JAX-RS and Jakarta RESTful web s . Enable MicroPRofile Telemetry, as described in <<#ol-config,Configuring Open Liberty to use MicroProfile Telemetry>>. -. xref:class-loader-library-configuration.adoc#3rd-party[Enable third-party APIs] for your application by adding the following code in your `server.xml` file: +. xref:class-loader-library-config.adoc#3rd-party[Enable third-party APIs] for your application by adding the following code in your `server.xml` file: + [source,xml] ---- @@ -239,6 +246,7 @@ The OpenTelemetry Java agent is a tool that is provided by the OpenTelemetry pro * The agent is not compatible with https://www.ibm.com/docs/en/was-liberty/base?topic=security-java-2[Java 2 security]. * Open Liberty uses many open source libraries internally. Some of these libraries might be automatically instrumented by the agent. +[#trouble] == Troubleshooting MicroProfile Telemetry The following information can help you determine the cause of common problems and error messages.