diff --git a/.gitignore b/.gitignore index befdd5814a2e..42e4e27f7515 100644 --- a/.gitignore +++ b/.gitignore @@ -57,7 +57,7 @@ derby.log hs_err_pid* replay_pid* .attach_pid* -**/.telemetry* +.telemetry* !java-agent/benchmark/releases/*.jar diff --git a/docs/instrumentation-list.yaml b/docs/instrumentation-list.yaml index 2f4fa6be038c..21da6cbb6646 100644 --- a/docs/instrumentation-list.yaml +++ b/docs/instrumentation-list.yaml @@ -167,6 +167,22 @@ libraries: target_versions: javaagent: - org.apache.httpcomponents.client5:httpclient5:[5.0,) + metrics: + - name: http.client.request.duration + description: Duration of HTTP client requests. + type: HISTOGRAM + unit: s + attributes: + - name: http.request.method + type: STRING + - name: http.response.status_code + type: LONG + - name: network.protocol.version + type: STRING + - name: server.address + type: STRING + - name: server.port + type: LONG - name: apache-dbcp-2.0 source_path: instrumentation/apache-dbcp-2.0 scope: @@ -176,6 +192,38 @@ libraries: - org.apache.commons:commons-dbcp2:[2,) library: - org.apache.commons:commons-dbcp2:2.0 + metrics: + - name: db.client.connections.usage + description: The number of connections that are currently in state described + by the state attribute. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: state + type: STRING + - name: db.client.connections.max + description: The maximum number of open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.idle.min + description: The minimum number of idle open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.idle.max + description: The maximum number of idle open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING armeria: - name: armeria-1.3 source_path: instrumentation/armeria/armeria-1.3 @@ -294,6 +342,35 @@ libraries: - software.amazon.awssdk:sqs:2.2.0 - software.amazon.awssdk:sns:2.2.0 - software.amazon.awssdk:lambda:2.2.0 + configurations: + - name: otel.instrumentation.messaging.experimental.receive-telemetry.enabled + description: Enables experimental receive telemetry for AWS SDK instrumentation. + type: boolean + default: false + - name: otel.instrumentation.messaging.experimental.capture-headers + description: Allows configuring headers to capture as span attributes. + type: list + default: '' + - name: otel.instrumentation.aws-sdk.experimental-span-attributes + description: Enables experimental span attributes for AWS SDK instrumentation. + type: boolean + default: false + - name: otel.instrumentation.aws-sdk.experimental-use-propagator-for-messaging + description: Determines whether the configured TextMapPropagator should be used + to inject into supported messaging attributes (for SQS). + type: boolean + default: false + - name: otel.instrumentation.genai.capture-message-content + description: Determines whether Generative AI events include full content of + user and assistant messages. Note that full content can have data privacy + and size concerns and care should be taken when enabling this + type: boolean + default: false + - name: otel.instrumentation.aws-sdk.experimental-record-individual-http-error + description: Determines whether errors returned by each individual HTTP request + should be recorded as events for the SDK span. + type: boolean + default: false azure: - name: azure-core-1.36 source_path: instrumentation/azure-core/azure-core-1.36 @@ -318,6 +395,8 @@ libraries: - com.azure:azure-core:[1.14.0,1.19.0) c3p0: - name: c3p0-0.9 + description: The c3p0 instrumentation provides connection pool metrics for c3p0 + data sources. source_path: instrumentation/c3p0-0.9 scope: name: io.opentelemetry.c3p0-0.9 @@ -326,14 +405,40 @@ libraries: - com.mchange:c3p0:(,) library: - com.mchange:c3p0:0.9.2 + metrics: + - name: db.client.connections.usage + description: The number of connections that are currently in state described + by the state attribute. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: state + type: STRING + - name: db.client.connections.pending_requests + description: The number of pending requests for an open connection, cumulative + for the entire pool. + type: LONG_SUM + unit: requests + attributes: + - name: pool.name + type: STRING camel: - name: camel-2.20 + description: | + This instrumentation provides tracing for Apache Camel 2.x applications by generating spans for each route execution. For Camel versions 3.5 and newer, users should instead use the native 'camel-opentelemetry' component provided directly by the Camel project. source_path: instrumentation/camel-2.20 scope: name: io.opentelemetry.camel-2.20 target_versions: javaagent: - org.apache.camel:camel-core:[2.19,3) + configurations: + - name: otel.instrumentation.camel.experimental-span-attributes + description: Enable the capture of experimental span attributes. + type: boolean + default: false cassandra: - name: cassandra-4.0 description: | @@ -396,6 +501,8 @@ libraries: default: true couchbase: - name: couchbase-3.1.6 + description: | + Couchbase instrumentation is owned by the Couchbase project. This instrumentation automatically configures the instrumentation provided by the Couchbase library. source_path: instrumentation/couchbase/couchbase-3.1.6 scope: name: io.opentelemetry.couchbase-3.1.6 @@ -409,6 +516,12 @@ libraries: target_versions: javaagent: - com.couchbase.client:java-client:[2.6.0,3) + configurations: + - name: otel.instrumentation.couchbase.experimental-span-attributes + description: Enables experimental span attributes couchbase.operation_id and + couchbase.local.address + type: boolean + default: false - name: couchbase-2.0 source_path: instrumentation/couchbase/couchbase-2.0 scope: @@ -416,7 +529,15 @@ libraries: target_versions: javaagent: - com.couchbase.client:java-client:[2,3) + configurations: + - name: otel.instrumentation.couchbase.experimental-span-attributes + description: Enables experimental span attributes couchbase.operation_id and + couchbase.local.address + type: boolean + default: false - name: couchbase-3.2 + description: | + Couchbase instrumentation is owned by the Couchbase project. This instrumentation automatically configures the instrumentation provided by the Couchbase library. source_path: instrumentation/couchbase/couchbase-3.2 scope: name: io.opentelemetry.couchbase-3.2 @@ -424,6 +545,8 @@ libraries: javaagent: - com.couchbase.client:java-client:[3.2.0,) - name: couchbase-3.1 + description: | + Couchbase instrumentation is owned by the Couchbase project. This instrumentation automatically configures the instrumentation provided by the Couchbase library. source_path: instrumentation/couchbase/couchbase-3.1 scope: name: io.opentelemetry.couchbase-3.1 @@ -432,6 +555,9 @@ libraries: - com.couchbase.client:java-client:[3.1,3.1.6) dropwizard: - name: dropwizard-metrics-4.0 + description: | + The dropwizard-metrics instrumentation for the dropwizard/codahale metrics library produces OpenTelemetry compliant versions of the metrics generated by the Dropwizard MetricRegistry. + The Dropwizard metrics API does not have a concept of metric labels/tags/attributes, thus the data produced by this integration might be of very low quality, depending on how the API is used in the instrumented application. disabled_by_default: true source_path: instrumentation/dropwizard/dropwizard-metrics-4.0 scope: @@ -439,6 +565,11 @@ libraries: target_versions: javaagent: - io.dropwizard.metrics:metrics-core:[4.0.0,) + configurations: + - name: otel.instrumentation.dropwizard-metrics.enabled + description: Enables the dropwizard metrics instrumentation. + type: boolean + default: false - name: dropwizard-views-0.7 source_path: instrumentation/dropwizard/dropwizard-views-0.7 scope: @@ -446,6 +577,15 @@ libraries: target_versions: javaagent: - io.dropwizard:dropwizard-views:(,3.0.0) + configurations: + - name: otel.instrumentation.common.experimental.view-telemetry.enabled + description: Enables experimental view telemetry. + type: boolean + default: false + - name: otel.instrumentation.common.experimental.controller-telemetry.enabled + description: Enables experimental controller telemetry. + type: boolean + default: false elasticsearch: - name: elasticsearch-rest-6.4 source_path: instrumentation/elasticsearch/elasticsearch-rest-6.4 @@ -668,6 +808,69 @@ libraries: - com.zaxxer:HikariCP:[3.0.0,) library: - com.zaxxer:HikariCP:3.0.0 + metrics: + - name: db.client.connections.wait_time + description: The time it took to obtain an open connection from the pool. + type: HISTOGRAM + unit: ms + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.usage + description: The number of connections that are currently in state described + by the state attribute. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: state + type: STRING + - name: db.client.connections.pending_requests + description: The number of pending requests for an open connection, cumulative + for the entire pool. + type: LONG_SUM + unit: requests + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.timeouts + description: The number of connection timeouts that have occurred trying to + obtain a connection from the pool. + type: LONG_SUM + unit: timeouts + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.max + description: The maximum number of open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.create_time + description: The time it took to create a new connection. + type: HISTOGRAM + unit: ms + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.idle.min + description: The minimum number of idle open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.use_time + description: The time between borrowing a connection and returning it to the + pool. + type: HISTOGRAM + unit: ms + attributes: + - name: pool.name + type: STRING http: - name: http-url-connection source_path: instrumentation/http-url-connection @@ -1316,6 +1519,8 @@ libraries: - org.opensearch.client:opensearch-rest-client:[1.0,3.0) oracle: - name: oracle-ucp-11.2 + description: The Oracle Universal Connection Pool (UCP) instrumentation generates + connection pool metrics. source_path: instrumentation/oracle-ucp-11.2 scope: name: io.opentelemetry.oracle-ucp-11.2 @@ -1325,8 +1530,37 @@ libraries: library: - com.oracle.database.jdbc:ucp:11.2.0.4 - com.oracle.database.jdbc:ojdbc8:12.2.0.1 + metrics: + - name: db.client.connections.usage + description: The number of connections that are currently in state described + by the state attribute. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: state + type: STRING + - name: db.client.connections.pending_requests + description: The number of pending requests for an open connection, cumulative + for the entire pool. + type: LONG_SUM + unit: requests + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.max + description: The maximum number of open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING oshi: - name: oshi + description: When the OSHI library is detected on the classpath, this instrumentation + will use the system class loader to load classes from the oshi-core jar that + are then used to generate system metrics. source_path: instrumentation/oshi scope: name: io.opentelemetry.oshi @@ -1335,6 +1569,85 @@ libraries: - com.github.oshi:oshi-core:[5.3.1,) library: - com.github.oshi:oshi-core:5.3.1 + configurations: + - name: otel.instrumentation.oshi.experimental-metrics.enabled + description: Enable the OSHI process metrics. + type: boolean + default: false + metrics: + - name: system.memory.utilization + description: System memory utilization + type: DOUBLE_GAUGE + unit: '1' + attributes: + - name: state + type: STRING + - name: system.network.packets + description: System network packets + type: LONG_SUM + unit: packets + attributes: + - name: device + type: STRING + - name: direction + type: STRING + - name: system.disk.operations + description: System disk operations + type: LONG_SUM + unit: operations + attributes: + - name: device + type: STRING + - name: direction + type: STRING + - name: runtime.java.cpu_time + description: Runtime Java CPU time + type: LONG_GAUGE + unit: ms + attributes: + - name: type + type: STRING + - name: runtime.java.memory + description: Runtime Java memory + type: LONG_SUM + unit: By + attributes: + - name: type + type: STRING + - name: system.disk.io + description: System disk IO + type: LONG_SUM + unit: By + attributes: + - name: device + type: STRING + - name: direction + type: STRING + - name: system.network.io + description: System network IO + type: LONG_SUM + unit: By + attributes: + - name: device + type: STRING + - name: direction + type: STRING + - name: system.memory.usage + description: System memory usage + type: LONG_SUM + unit: By + attributes: + - name: state + type: STRING + - name: system.network.errors + description: System network errors + type: LONG_SUM + unit: errors + attributes: + - name: device + type: STRING + - name: direction + type: STRING payara: - name: payara source_path: instrumentation/payara @@ -1910,6 +2223,46 @@ libraries: target_versions: javaagent: - org.apache.tomcat:tomcat-jdbc:[8.5.0,) + metrics: + - name: db.client.connections.usage + description: The number of connections that are currently in state described + by the state attribute. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: state + type: STRING + - name: db.client.connections.pending_requests + description: The number of pending requests for an open connection, cumulative + for the entire pool. + type: LONG_SUM + unit: requests + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.max + description: The maximum number of open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.idle.min + description: The minimum number of idle open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: db.client.connections.idle.max + description: The maximum number of idle open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING twilio: - name: twilio-6.6 source_path: instrumentation/twilio-6.6 @@ -2003,6 +2356,8 @@ libraries: - io.vertx:vertx-core:[3.0.0,4.0.0) vibur: - name: vibur-dbcp-11.0 + description: Instrumentation for the vibur-dbcp library, which provides connection + pool metrics. source_path: instrumentation/vibur-dbcp-11.0 scope: name: io.opentelemetry.vibur-dbcp-11.0 @@ -2011,6 +2366,24 @@ libraries: - org.vibur:vibur-dbcp:[11.0,) library: - org.vibur:vibur-dbcp:11.0 + metrics: + - name: db.client.connections.usage + description: The number of connections that are currently in state described + by the state attribute. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING + - name: state + type: STRING + - name: db.client.connections.max + description: The maximum number of open connections allowed. + type: LONG_SUM + unit: connections + attributes: + - name: pool.name + type: STRING wicket: - name: wicket-8.0 source_path: instrumentation/wicket-8.0 diff --git a/instrumentation-docs/collect.sh b/instrumentation-docs/collect.sh index 8d61395d70a4..6d51b9fcee15 100755 --- a/instrumentation-docs/collect.sh +++ b/instrumentation-docs/collect.sh @@ -1,51 +1,133 @@ -#!/bin/bash +#!/usr/bin/env bash -instrumentations=( +# Runs selected Gradle test tasks to regenerate *.telemetry output for +# individual OpenTelemetry Java agent instrumentations. + +set -euo pipefail + +# Oracle UCP won't run on Apple Silicon, so we need to use colima to run as x86_64 +if [[ "$(uname -m)" == "arm64" || "$(uname -m)" == "aarch64" ]]; then + colima start --arch x86_64 --memory 4 + export TESTCONTAINERS_DOCKER_SOCKET_OVERRIDE=/var/run/docker.sock + export DOCKER_HOST="unix://${HOME}/.colima/docker.sock" +fi + +readonly INSTRUMENTATIONS=( + # : : [ gradle-task-suffix ] + "apache-dbcp-2.0:javaagent:test" + "apache-httpclient:apache-httpclient-5.0:javaagent:test" "alibaba-druid-1.0:javaagent:test" + "c3p0-0.9:javaagent:test" + "hikaricp-3.0:javaagent:test" + "tomcat:tomcat-jdbc:javaagent:test" + "oracle-ucp-11.2:javaagent:test" + "oshi:javaagent:test" + "vibur-dbcp-11.0:javaagent:test" ) -# Initialize an empty string to hold the Gradle tasks -gradle_tasks="" - -# Iterate over each instrumentation -for instrumentation in "${instrumentations[@]}"; do - # Extract the parts of the instrumentation - IFS=':' read -r -a parts <<< "$instrumentation" - module="${parts[0]}" - version="${parts[1]}" - type="${parts[2]}" - suffix="${parts[3]}" - - # Assemble the path to the instrumentation - path="instrumentation/$module/$version" - - # Remove any occurrence of /javaagent/ or /library/ from the path - path=$(echo "$path" | sed -e 's/\/javaagent//g' -e 's/\/library//g') - - # Debugging: Print the path being checked - echo "Checking path: $path/.telemetry" - - # Check if the .telemetry directory exists and remove it if it does - if [ -d "$path/.telemetry" ]; then - echo "Removing directory: $path/.telemetry" - rm -rf "$path/.telemetry" - else - echo "Directory does not exist: $path/.telemetry" +readonly TELEMETRY_DIR_NAME=".telemetry" + +# Splits a single descriptor into its three logical parts. +# argument $1: descriptor string (ex: "foo:bar:baz:test") +# Outputs three variables via echo: +# 1. module_path - instrumentation/foo/bar +# 2. task_type - javaagent | library +# 3. task_suffix - test +parse_descriptor() { + local descriptor="$1" + local -a parts + + # Convert colon-delimited string into array + IFS=':' read -r -a parts <<< "$descriptor" + + # Locate "javaagent" or "library" token (there should be exactly one) + local type_idx=-1 + for i in "${!parts[@]}"; do + if [[ ${parts[$i]} == "javaagent" || ${parts[$i]} == "library" ]]; then + type_idx=$i + break + fi + done + + if [[ $type_idx -lt 0 ]]; then + echo "ERROR: malformed descriptor: $descriptor" >&2 + return 1 + fi + + local task_type="${parts[$type_idx]}" + + # Optional suffix lives after the type token + local task_suffix="" + if (( type_idx + 1 < ${#parts[@]} )); then + task_suffix="${parts[$((type_idx + 1))]}" + fi + + # Join everything before the type token with slashes to make instrumentation//... + local path_segments=("${parts[@]:0:type_idx}") + local module_path + IFS=/ module_path="instrumentation/${path_segments[*]}" + + echo "$module_path" "$task_type" "$task_suffix" +} + +# Removes a .telemetry directory if it exists under the given module path. +delete_existing_telemetry() { + local module_path="$1" + local telemetry_path="$module_path/$TELEMETRY_DIR_NAME" + + if [[ -d "$telemetry_path" ]]; then + rm -rf "$telemetry_path" fi +} + +# Converts the three parsed parts into a Gradle task name. +# ex: instrumentation:foo:bar:javaagent:test +build_gradle_task() { + local module_path="$1" # instrumentation/foo/bar + local task_type="$2" # javaagent | library + local task_suffix="$3" # test | + + # replace slashes with colons, then append task parts + local module_colon_path="${module_path//\//:}" + local task=":$module_colon_path:$task_type" + + [[ -n $task_suffix ]] && task+=":$task_suffix" + echo "$task" +} - # Append the Gradle task to the gradle_tasks string with a colon between type and suffix if suffix is non-empty - if [ -n "$suffix" ]; then - gradle_tasks+=":instrumentation:$module:$version:$type:$suffix" - else - gradle_tasks+=":instrumentation:$module:$version:$type" +# Cleans any stray .telemetry directories left in the repo. +find_and_remove_all_telemetry() { + echo "Removing stray .telemetry directories..." + find . -type d -name "$TELEMETRY_DIR_NAME" -exec rm -rf {} + +} + +# Main +declare -a gradle_tasks=() + +for descriptor in "${INSTRUMENTATIONS[@]}"; do + # Parse the descriptor into its components + if ! read -r module_path task_type task_suffix \ + < <(parse_descriptor "$descriptor"); then + continue # skip any badly formed descriptors fi + + # Make sure we’re starting fresh for this instrumentation + delete_existing_telemetry "$module_path" + + # Build the Gradle task string and queue it + gradle_tasks+=( "$(build_gradle_task "$module_path" "$task_type" "$task_suffix")" ) done -# rerun-tasks is used to force re-running tests that might be cached -echo Running: ./gradlew "$gradle_tasks" -PcollectMetadata=true --rerun-tasks -./gradlew "$gradle_tasks" -PcollectMetadata=true --rerun-tasks -./gradlew :instrumentation-docs:runAnalysis +echo +echo "Running Gradle tasks:" +printf ' %s\n' "${gradle_tasks[@]}" +echo + +./gradlew "${gradle_tasks[@]}" \ + -PcollectMetadata=true \ + --rerun-tasks + +# uncomment the next line to remove all .telemetry directories +#find_and_remove_all_telemetry -# Remove all .telemetry directories recursively from the project root -echo "Searching for and removing all .telemetry directories..." -find . -type d -name ".telemetry" -exec rm -rf {} + +echo "Telemetry file regeneration complete." diff --git a/instrumentation/apache-dbcp-2.0/javaagent/build.gradle.kts b/instrumentation/apache-dbcp-2.0/javaagent/build.gradle.kts index a08644e701c9..54020d8dfded 100644 --- a/instrumentation/apache-dbcp-2.0/javaagent/build.gradle.kts +++ b/instrumentation/apache-dbcp-2.0/javaagent/build.gradle.kts @@ -24,6 +24,10 @@ tasks { jvmArgs("-Dotel.semconv-stability.opt-in=database") } + test { + systemProperty("collectMetadata", findProperty("collectMetadata")?.toString() ?: "false") + } + check { dependsOn(testStableSemconv) } diff --git a/instrumentation/apache-httpclient/apache-httpclient-5.0/javaagent/build.gradle.kts b/instrumentation/apache-httpclient/apache-httpclient-5.0/javaagent/build.gradle.kts index 86a92a3636b2..e40db9cbcdce 100644 --- a/instrumentation/apache-httpclient/apache-httpclient-5.0/javaagent/build.gradle.kts +++ b/instrumentation/apache-httpclient/apache-httpclient-5.0/javaagent/build.gradle.kts @@ -20,4 +20,8 @@ tasks { withType().configureEach { systemProperty("testLatestDeps", findProperty("testLatestDeps") as Boolean) } + + test { + systemProperty("collectMetadata", findProperty("collectMetadata")?.toString() ?: "false") + } } diff --git a/instrumentation/aws-sdk/aws-sdk-2.2/metadata.yaml b/instrumentation/aws-sdk/aws-sdk-2.2/metadata.yaml new file mode 100644 index 000000000000..732d5818dd7e --- /dev/null +++ b/instrumentation/aws-sdk/aws-sdk-2.2/metadata.yaml @@ -0,0 +1,25 @@ +configurations: + - name: otel.instrumentation.messaging.experimental.receive-telemetry.enabled + description: Enables experimental receive telemetry for AWS SDK instrumentation. + type: boolean + default: false + - name: otel.instrumentation.messaging.experimental.capture-headers + description: Allows configuring headers to capture as span attributes. + type: list + default: '' + - name: otel.instrumentation.aws-sdk.experimental-span-attributes + description: Enables experimental span attributes for AWS SDK instrumentation. + type: boolean + default: false + - name: otel.instrumentation.aws-sdk.experimental-use-propagator-for-messaging + description: Determines whether the configured TextMapPropagator should be used to inject into supported messaging attributes (for SQS). + type: boolean + default: false + - name: otel.instrumentation.genai.capture-message-content + description: Determines whether Generative AI events include full content of user and assistant messages. Note that full content can have data privacy and size concerns and care should be taken when enabling this + type: boolean + default: false + - name: otel.instrumentation.aws-sdk.experimental-record-individual-http-error + description: Determines whether errors returned by each individual HTTP request should be recorded as events for the SDK span. + type: boolean + default: false diff --git a/instrumentation/c3p0-0.9/javaagent/build.gradle.kts b/instrumentation/c3p0-0.9/javaagent/build.gradle.kts index eb97e869462f..483910939081 100644 --- a/instrumentation/c3p0-0.9/javaagent/build.gradle.kts +++ b/instrumentation/c3p0-0.9/javaagent/build.gradle.kts @@ -26,6 +26,10 @@ tasks { jvmArgs("-Dotel.semconv-stability.opt-in=database") } + test { + systemProperty("collectMetadata", findProperty("collectMetadata")?.toString() ?: "false") + } + check { dependsOn(testStableSemconv) } diff --git a/instrumentation/c3p0-0.9/metadata.yaml b/instrumentation/c3p0-0.9/metadata.yaml new file mode 100644 index 000000000000..0c307d232160 --- /dev/null +++ b/instrumentation/c3p0-0.9/metadata.yaml @@ -0,0 +1 @@ +description: The c3p0 instrumentation provides connection pool metrics for c3p0 data sources. diff --git a/instrumentation/camel-2.20/metadata.yaml b/instrumentation/camel-2.20/metadata.yaml new file mode 100644 index 000000000000..b3e34843018f --- /dev/null +++ b/instrumentation/camel-2.20/metadata.yaml @@ -0,0 +1,9 @@ +description: > + This instrumentation provides tracing for Apache Camel 2.x applications by generating spans for + each route execution. For Camel versions 3.5 and newer, users should instead use the native + 'camel-opentelemetry' component provided directly by the Camel project. +configurations: + - name: otel.instrumentation.camel.experimental-span-attributes + description: Enable the capture of experimental span attributes. + type: boolean + default: false diff --git a/instrumentation/couchbase/README.md b/instrumentation/couchbase/README.md index 2258abb0a49f..2888eff93e74 100644 --- a/instrumentation/couchbase/README.md +++ b/instrumentation/couchbase/README.md @@ -1,5 +1,5 @@ # Settings for the Couchbase instrumentation -| System property | Type | Default | Description | -| ------------------------------------------------------------- | ------- | ------- | --------------------------------------------------------------------------------------------------------- | -| `otel.instrumentation.couchbase.experimental-span-attributes` | Boolean | `false` | Enables the capture of experimental span attributes (for version 2.6 and higher of this instrumentation). | +| System property | Type | Default | Description | +|---------------------------------------------------------------|---------|---------|-------------------------------------------------------------------------| +| `otel.instrumentation.couchbase.experimental-span-attributes` | Boolean | `false` | Enables the capture of experimental span attributes (for 2.x versions). | diff --git a/instrumentation/couchbase/couchbase-2.0/metadata.yaml b/instrumentation/couchbase/couchbase-2.0/metadata.yaml new file mode 100644 index 000000000000..a91bbaa98dab --- /dev/null +++ b/instrumentation/couchbase/couchbase-2.0/metadata.yaml @@ -0,0 +1,5 @@ +configurations: + - name: otel.instrumentation.couchbase.experimental-span-attributes + description: Enables experimental span attributes couchbase.operation_id and couchbase.local.address + type: boolean + default: false diff --git a/instrumentation/couchbase/couchbase-2.6/metadata.yaml b/instrumentation/couchbase/couchbase-2.6/metadata.yaml new file mode 100644 index 000000000000..a91bbaa98dab --- /dev/null +++ b/instrumentation/couchbase/couchbase-2.6/metadata.yaml @@ -0,0 +1,5 @@ +configurations: + - name: otel.instrumentation.couchbase.experimental-span-attributes + description: Enables experimental span attributes couchbase.operation_id and couchbase.local.address + type: boolean + default: false diff --git a/instrumentation/couchbase/couchbase-3.1.6/metadata.yaml b/instrumentation/couchbase/couchbase-3.1.6/metadata.yaml new file mode 100644 index 000000000000..3fec95f03fcf --- /dev/null +++ b/instrumentation/couchbase/couchbase-3.1.6/metadata.yaml @@ -0,0 +1,3 @@ +description: > + Couchbase instrumentation is owned by the Couchbase project. This instrumentation automatically + configures the instrumentation provided by the Couchbase library. diff --git a/instrumentation/couchbase/couchbase-3.1/metadata.yaml b/instrumentation/couchbase/couchbase-3.1/metadata.yaml new file mode 100644 index 000000000000..3fec95f03fcf --- /dev/null +++ b/instrumentation/couchbase/couchbase-3.1/metadata.yaml @@ -0,0 +1,3 @@ +description: > + Couchbase instrumentation is owned by the Couchbase project. This instrumentation automatically + configures the instrumentation provided by the Couchbase library. diff --git a/instrumentation/couchbase/couchbase-3.2/metadata.yaml b/instrumentation/couchbase/couchbase-3.2/metadata.yaml new file mode 100644 index 000000000000..3fec95f03fcf --- /dev/null +++ b/instrumentation/couchbase/couchbase-3.2/metadata.yaml @@ -0,0 +1,3 @@ +description: > + Couchbase instrumentation is owned by the Couchbase project. This instrumentation automatically + configures the instrumentation provided by the Couchbase library. diff --git a/instrumentation/dropwizard/dropwizard-metrics-4.0/metadata.yaml b/instrumentation/dropwizard/dropwizard-metrics-4.0/metadata.yaml index 1aee203e711b..930c129fa366 100644 --- a/instrumentation/dropwizard/dropwizard-metrics-4.0/metadata.yaml +++ b/instrumentation/dropwizard/dropwizard-metrics-4.0/metadata.yaml @@ -1 +1,13 @@ +description: > + The dropwizard-metrics instrumentation for the dropwizard/codahale metrics library produces + OpenTelemetry compliant versions of the metrics generated by the Dropwizard MetricRegistry. + + The Dropwizard metrics API does not have a concept of metric labels/tags/attributes, thus the data + produced by this integration might be of very low quality, depending on how the API is used in the + instrumented application. disabled_by_default: true +configurations: + - name: otel.instrumentation.dropwizard-metrics.enabled + description: Enables the dropwizard metrics instrumentation. + type: boolean + default: false diff --git a/instrumentation/dropwizard/dropwizard-views-0.7/metadata.yaml b/instrumentation/dropwizard/dropwizard-views-0.7/metadata.yaml new file mode 100644 index 000000000000..96cd260f9316 --- /dev/null +++ b/instrumentation/dropwizard/dropwizard-views-0.7/metadata.yaml @@ -0,0 +1,9 @@ +configurations: + - name: otel.instrumentation.common.experimental.view-telemetry.enabled + description: Enables experimental view telemetry. + type: boolean + default: false + - name: otel.instrumentation.common.experimental.controller-telemetry.enabled + description: Enables experimental controller telemetry. + type: boolean + default: false diff --git a/instrumentation/hikaricp-3.0/javaagent/build.gradle.kts b/instrumentation/hikaricp-3.0/javaagent/build.gradle.kts index 714af1aaef50..ad2f01808c53 100644 --- a/instrumentation/hikaricp-3.0/javaagent/build.gradle.kts +++ b/instrumentation/hikaricp-3.0/javaagent/build.gradle.kts @@ -27,6 +27,10 @@ tasks { jvmArgs("-Dotel.semconv-stability.opt-in=database") } + test { + systemProperty("collectMetadata", findProperty("collectMetadata")?.toString() ?: "false") + } + check { dependsOn(testStableSemconv) } diff --git a/instrumentation/oracle-ucp-11.2/javaagent/build.gradle.kts b/instrumentation/oracle-ucp-11.2/javaagent/build.gradle.kts index ce212bdd92dc..3438caf2215b 100644 --- a/instrumentation/oracle-ucp-11.2/javaagent/build.gradle.kts +++ b/instrumentation/oracle-ucp-11.2/javaagent/build.gradle.kts @@ -29,6 +29,10 @@ tasks { jvmArgs("-Dotel.semconv-stability.opt-in=database") } + test { + systemProperty("collectMetadata", findProperty("collectMetadata")?.toString() ?: "false") + } + check { dependsOn(testStableSemconv) } diff --git a/instrumentation/oracle-ucp-11.2/metadata.yaml b/instrumentation/oracle-ucp-11.2/metadata.yaml new file mode 100644 index 000000000000..b44ec44abf52 --- /dev/null +++ b/instrumentation/oracle-ucp-11.2/metadata.yaml @@ -0,0 +1 @@ +description: The Oracle Universal Connection Pool (UCP) instrumentation generates connection pool metrics. diff --git a/instrumentation/oshi/javaagent/build.gradle.kts b/instrumentation/oshi/javaagent/build.gradle.kts index c92fd36aa4fe..61bbb729f4c8 100644 --- a/instrumentation/oshi/javaagent/build.gradle.kts +++ b/instrumentation/oshi/javaagent/build.gradle.kts @@ -26,4 +26,8 @@ tasks { withType().configureEach { jvmArgs("-Dotel.instrumentation.oshi.experimental-metrics.enabled=true") } + + test { + systemProperty("collectMetadata", findProperty("collectMetadata")?.toString() ?: "false") + } } diff --git a/instrumentation/oshi/metadata.yaml b/instrumentation/oshi/metadata.yaml new file mode 100644 index 000000000000..0afedf010d6a --- /dev/null +++ b/instrumentation/oshi/metadata.yaml @@ -0,0 +1,6 @@ +description: When the OSHI library is detected on the classpath, this instrumentation will use the system class loader to load classes from the oshi-core jar that are then used to generate system metrics. +configurations: + - name: otel.instrumentation.oshi.experimental-metrics.enabled + description: Enable the OSHI process metrics. + type: boolean + default: false diff --git a/instrumentation/tomcat/tomcat-jdbc/javaagent/build.gradle.kts b/instrumentation/tomcat/tomcat-jdbc/javaagent/build.gradle.kts index ab8684db2fd1..47541bf80e47 100644 --- a/instrumentation/tomcat/tomcat-jdbc/javaagent/build.gradle.kts +++ b/instrumentation/tomcat/tomcat-jdbc/javaagent/build.gradle.kts @@ -15,3 +15,9 @@ dependencies { compileOnly("org.apache.tomcat:tomcat-jdbc:8.5.0") testImplementation("org.apache.tomcat:tomcat-jdbc:8.5.0") } + +tasks { + test { + systemProperty("collectMetadata", findProperty("collectMetadata")?.toString() ?: "false") + } +} diff --git a/instrumentation/vibur-dbcp-11.0/javaagent/build.gradle.kts b/instrumentation/vibur-dbcp-11.0/javaagent/build.gradle.kts index 01476009a2e2..601ffb6e066b 100644 --- a/instrumentation/vibur-dbcp-11.0/javaagent/build.gradle.kts +++ b/instrumentation/vibur-dbcp-11.0/javaagent/build.gradle.kts @@ -24,6 +24,10 @@ tasks { jvmArgs("-Dotel.semconv-stability.opt-in=database") } + test { + systemProperty("collectMetadata", findProperty("collectMetadata")?.toString() ?: "false") + } + check { dependsOn(testStableSemconv) } diff --git a/instrumentation/vibur-dbcp-11.0/metadata.yaml b/instrumentation/vibur-dbcp-11.0/metadata.yaml new file mode 100644 index 000000000000..991cdddecce9 --- /dev/null +++ b/instrumentation/vibur-dbcp-11.0/metadata.yaml @@ -0,0 +1 @@ +description: Instrumentation for the vibur-dbcp library, which provides connection pool metrics.