From 2587e98c351e9fa6bec428c4197d3aa55bef4058 Mon Sep 17 00:00:00 2001 From: Jay DeLuca Date: Mon, 17 Nov 2025 13:53:43 -0500 Subject: [PATCH 1/2] remove kafka metric assertion --- docs/instrumentation-list.yaml | 262 ++++++++++++++++++ .../v0_11/KafkaClientDefaultTest.java | 11 - 2 files changed, 262 insertions(+), 11 deletions(-) diff --git a/docs/instrumentation-list.yaml b/docs/instrumentation-list.yaml index 3d87266408e8..d6152eeda5f8 100644 --- a/docs/instrumentation-list.yaml +++ b/docs/instrumentation-list.yaml @@ -8346,13 +8346,88 @@ libraries: source_path: instrumentation/ktor/ktor-1.0 scope: name: io.opentelemetry.ktor-1.0 + schema_url: https://opentelemetry.io/schemas/1.37.0 target_versions: library: - io.ktor:ktor-server-core:[1.0.0,1.+) + telemetry: + - when: default + metrics: + - name: http.server.request.duration + description: Duration of HTTP server requests. + type: HISTOGRAM + unit: s + attributes: + - name: http.request.method + type: STRING + - name: http.response.status_code + type: LONG + - name: http.route + type: STRING + - name: network.protocol.version + type: STRING + - name: url.scheme + type: STRING + spans: + - span_kind: CONSUMER + attributes: + - name: client.address + type: STRING + - name: http.request.method + type: STRING + - name: http.response.status_code + type: LONG + - name: network.peer.address + type: STRING + - name: network.protocol.version + type: STRING + - name: server.address + type: STRING + - name: server.port + type: LONG + - name: url.path + type: STRING + - name: url.query + type: STRING + - name: url.scheme + type: STRING + - name: user_agent.original + type: STRING + - span_kind: SERVER + attributes: + - name: client.address + type: STRING + - name: error.type + type: STRING + - name: http.request.method + type: STRING + - name: http.request.method_original + type: STRING + - name: http.response.status_code + type: LONG + - name: http.route + type: STRING + - name: network.peer.address + type: STRING + - name: network.protocol.version + type: STRING + - name: server.address + type: STRING + - name: server.port + type: LONG + - name: url.path + type: STRING + - name: url.query + type: STRING + - name: url.scheme + type: STRING + - name: user_agent.original + type: STRING - name: ktor-2.0 source_path: instrumentation/ktor/ktor-2.0 scope: name: io.opentelemetry.ktor-2.0 + schema_url: https://opentelemetry.io/schemas/1.37.0 target_versions: javaagent: - io.ktor:ktor-client-core:[2.0.0,3.0.0) @@ -8360,10 +8435,115 @@ libraries: library: - io.ktor:ktor-client-core:[2.0.0,2.+) - io.ktor:ktor-server-core:[2.0.0,2.+) + telemetry: + - when: default + 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: http.server.request.duration + description: Duration of HTTP server requests. + type: HISTOGRAM + unit: s + attributes: + - name: http.request.method + type: STRING + - name: http.response.status_code + type: LONG + - name: http.route + type: STRING + - name: network.protocol.version + type: STRING + - name: url.scheme + type: STRING + spans: + - span_kind: CLIENT + attributes: + - name: error.type + type: STRING + - name: http.request.method + type: STRING + - name: http.request.method_original + type: STRING + - name: http.request.resend_count + type: LONG + - name: http.response.status_code + type: LONG + - name: network.protocol.version + type: STRING + - name: server.address + type: STRING + - name: server.port + type: LONG + - name: url.full + type: STRING + - span_kind: CONSUMER + attributes: + - name: client.address + type: STRING + - 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: url.path + type: STRING + - name: url.query + type: STRING + - name: url.scheme + type: STRING + - name: user_agent.original + type: STRING + - span_kind: SERVER + attributes: + - name: client.address + type: STRING + - name: error.type + type: STRING + - name: http.request.method + type: STRING + - name: http.request.method_original + type: STRING + - name: http.response.status_code + type: LONG + - name: http.route + type: STRING + - name: network.protocol.version + type: STRING + - name: server.address + type: STRING + - name: server.port + type: LONG + - name: url.path + type: STRING + - name: url.query + type: STRING + - name: url.scheme + type: STRING + - name: user_agent.original + type: STRING - name: ktor-3.0 source_path: instrumentation/ktor/ktor-3.0 scope: name: io.opentelemetry.ktor-3.0 + schema_url: https://opentelemetry.io/schemas/1.37.0 target_versions: javaagent: - io.ktor:ktor-server-core:[3.0.0,) @@ -8371,6 +8551,88 @@ libraries: library: - io.ktor:ktor-server-core:3.0.0 - io.ktor:ktor-client-core:3.0.0 + telemetry: + - when: default + 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: http.server.request.duration + description: Duration of HTTP server requests. + type: HISTOGRAM + unit: s + attributes: + - name: http.request.method + type: STRING + - name: http.response.status_code + type: LONG + - name: http.route + type: STRING + - name: network.protocol.version + type: STRING + - name: url.scheme + type: STRING + spans: + - span_kind: CLIENT + attributes: + - name: error.type + type: STRING + - name: http.request.method + type: STRING + - name: http.request.method_original + type: STRING + - name: http.request.resend_count + type: LONG + - name: http.response.status_code + type: LONG + - name: network.protocol.version + type: STRING + - name: server.address + type: STRING + - name: server.port + type: LONG + - name: url.full + type: STRING + - span_kind: SERVER + attributes: + - name: client.address + type: STRING + - name: error.type + type: STRING + - name: http.request.method + type: STRING + - name: http.request.method_original + type: STRING + - name: http.response.status_code + type: LONG + - name: http.route + type: STRING + - name: network.protocol.version + type: STRING + - name: server.address + type: STRING + - name: server.port + type: LONG + - name: url.path + type: STRING + - name: url.query + type: STRING + - name: url.scheme + type: STRING + - name: user_agent.original + type: STRING kubernetes: - name: kubernetes-client-7.0 source_path: instrumentation/kubernetes-client-7.0 diff --git a/instrumentation/kafka/kafka-clients/kafka-clients-0.11/javaagent/src/test/java/io/opentelemetry/javaagent/instrumentation/kafkaclients/v0_11/KafkaClientDefaultTest.java b/instrumentation/kafka/kafka-clients/kafka-clients-0.11/javaagent/src/test/java/io/opentelemetry/javaagent/instrumentation/kafkaclients/v0_11/KafkaClientDefaultTest.java index 61e2474a1f72..51fd690bba3c 100644 --- a/instrumentation/kafka/kafka-clients/kafka-clients-0.11/javaagent/src/test/java/io/opentelemetry/javaagent/instrumentation/kafkaclients/v0_11/KafkaClientDefaultTest.java +++ b/instrumentation/kafka/kafka-clients/kafka-clients-0.11/javaagent/src/test/java/io/opentelemetry/javaagent/instrumentation/kafkaclients/v0_11/KafkaClientDefaultTest.java @@ -26,7 +26,6 @@ import org.apache.kafka.clients.consumer.ConsumerRecord; import org.apache.kafka.clients.consumer.ConsumerRecords; import org.apache.kafka.clients.producer.ProducerRecord; -import org.assertj.core.api.AbstractIterableAssert; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.RegisterExtension; @@ -35,9 +34,6 @@ class KafkaClientDefaultTest extends KafkaClientPropagationBaseTest { - private static final boolean testLatestDeps = - Boolean.parseBoolean(System.getProperty("testLatestDeps", "true")); - @RegisterExtension static final InstrumentationExtension testing = AgentInstrumentationExtension.create(); @@ -114,13 +110,6 @@ void testKafkaProducerAndConsumerSpan(boolean testHeaders) throws Exception { .hasAttributesSatisfyingExactly( processAttributes("10", greeting, testHeaders, false)), span -> span.hasName("processing").hasParent(trace.getSpan(1)))); - - if (testLatestDeps) { - testing.waitAndAssertMetrics( - "io.opentelemetry.kafka-clients-0.11", - "kafka.producer.record_send_total", - AbstractIterableAssert::isNotEmpty); - } } @DisplayName("test pass through tombstone") From 7fef9b02313cf3ed47148568c25b0943fd84cc2e Mon Sep 17 00:00:00 2001 From: Jay DeLuca Date: Mon, 17 Nov 2025 14:01:50 -0500 Subject: [PATCH 2/2] remove kafka metric assertion --- docs/instrumentation-list.yaml | 1721 ++--------------- .../kafkaclients/v2_6/InterceptorsTest.java | 6 - 2 files changed, 141 insertions(+), 1586 deletions(-) diff --git a/docs/instrumentation-list.yaml b/docs/instrumentation-list.yaml index d6152eeda5f8..ad25621ebcc4 100644 --- a/docs/instrumentation-list.yaml +++ b/docs/instrumentation-list.yaml @@ -7003,1636 +7003,197 @@ libraries: - org.apache.kafka:kafka-clients:2.6.0 telemetry: - when: default - metrics: - - name: kafka.consumer.assigned_partitions - description: The number of partitions currently assigned to this consumer - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.bytes_consumed_rate - description: The average number of bytes consumed per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.bytes_consumed_total - description: The total number of bytes consumed - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.commit_latency_avg - description: The average time taken for a commit request - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.commit_latency_max - description: The max time taken for a commit request - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.commit_rate - description: The number of commit calls per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.commit_total - description: The total number of commit calls - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.connection_close_rate - description: The number of connections closed per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.connection_close_total - description: The total number of connections closed - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.connection_count - description: The current number of active connections. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.connection_creation_rate - description: The number of new connections established per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.connection_creation_total - description: The total number of new connections established - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.failed_authentication_rate - description: The number of connections with failed authentication per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.failed_authentication_total - description: The total number of connections with failed authentication - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.failed_reauthentication_rate - description: The number of failed re-authentication of connections per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.failed_reauthentication_total - description: The total number of failed re-authentication of connections - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.failed_rebalance_rate_per_hour - description: The number of failed rebalance events per hour - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.failed_rebalance_total - description: The total number of failed rebalance events - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.fetch_latency_avg - description: The average time taken for a fetch request. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.fetch_latency_max - description: The max time taken for any fetch request. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.fetch_rate - description: The number of fetch requests per second. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.fetch_size_avg - description: The average number of bytes fetched per request - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.fetch_size_max - description: The maximum number of bytes fetched per request - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.fetch_throttle_time_avg - description: The average throttle time in ms - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.fetch_throttle_time_max - description: The maximum throttle time in ms - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.fetch_total - description: The total number of fetch requests. - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.heartbeat_rate - description: The number of heartbeats per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.heartbeat_total - description: The total number of heartbeats - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.incoming_byte_rate - description: The number of bytes read off all sockets per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.incoming_byte_total - description: The total number of bytes read off all sockets - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.io_ratio - description: The fraction of time the I/O thread spent doing I/O - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.io_time_ns_avg - description: The average length of time for I/O per select call in nanoseconds. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.io_wait_ratio - description: The fraction of time the I/O thread spent waiting - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.io_wait_time_ns_avg - description: The average length of time the I/O thread spent waiting for a - socket ready for reads or writes in nanoseconds. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.io_waittime_total - description: The total time the I/O thread spent waiting - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.iotime_total - description: The total time the I/O thread spent doing I/O - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.join_rate - description: The number of group joins per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.join_time_avg - description: The average time taken for a group rejoin - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.join_time_max - description: The max time taken for a group rejoin - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.join_total - description: The total number of group joins - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.last_heartbeat_seconds_ago - description: The number of seconds since the last coordinator heartbeat was - sent - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.last_poll_seconds_ago - description: The number of seconds since the last poll() invocation. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.last_rebalance_seconds_ago - description: The number of seconds since the last successful rebalance event - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.network_io_rate - description: The number of network operations (reads or writes) on all connections - per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.network_io_total - description: The total number of network operations (reads or writes) on all - connections - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.outgoing_byte_rate - description: The number of outgoing bytes sent to all servers per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.outgoing_byte_total - description: The total number of outgoing bytes sent to all servers - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.partition_assigned_latency_avg - description: The average time taken for a partition-assigned rebalance listener - callback - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.partition_assigned_latency_max - description: The max time taken for a partition-assigned rebalance listener - callback - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.poll_idle_ratio_avg - description: The average fraction of time the consumer's poll() is idle as - opposed to waiting for the user code to process records. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.rebalance_latency_avg - description: The average time taken for a group to complete a successful rebalance, - which may be composed of several failed re-trials until it succeeded - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.rebalance_latency_max - description: The max time taken for a group to complete a successful rebalance, - which may be composed of several failed re-trials until it succeeded - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.rebalance_latency_total - description: The total number of milliseconds this consumer has spent in successful - rebalances since creation - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.rebalance_rate_per_hour - description: The number of successful rebalance events per hour, each event - is composed of several failed re-trials until it succeeded - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.rebalance_total - description: The total number of successful rebalance events, each event is - composed of several failed re-trials until it succeeded - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.records_consumed_rate - description: The average number of records consumed per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.records_consumed_total - description: The total number of records consumed - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.records_lag - description: The latest lag of the partition - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: partition - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.records_lag_avg - description: The average lag of the partition - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: partition - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.records_lag_max - description: The maximum lag in terms of number of records for any partition - in this window - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: partition - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.records_lead - description: The latest lead of the partition - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: partition - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.records_lead_avg - description: The average lead of the partition - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: partition - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.records_lead_min - description: The minimum lead in terms of number of records for any partition - in this window - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: partition - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.records_per_request_avg - description: The average number of records in each request - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.consumer.request_rate - description: The number of requests sent per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.request_size_avg - description: The average size of requests sent. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.request_size_max - description: The maximum size of any request sent. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.request_total - description: The total number of requests sent - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.response_rate - description: The number of responses received per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.response_total - description: The total number of responses received - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.consumer.select_rate - description: The number of times the I/O layer checked for new I/O to perform - per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.select_total - description: The total number of times the I/O layer checked for new I/O to - perform - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.successful_authentication_no_reauth_total - description: The total number of connections with successful authentication - where the client does not support re-authentication - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.successful_authentication_rate - description: The number of connections with successful authentication per - second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.successful_authentication_total - description: The total number of connections with successful authentication - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.successful_reauthentication_rate - description: The number of successful re-authentication of connections per - second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.successful_reauthentication_total - description: The total number of successful re-authentication of connections - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.sync_rate - description: The number of group syncs per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.sync_time_avg - description: The average time taken for a group sync - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.sync_time_max - description: The max time taken for a group sync - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.sync_total - description: The total number of group syncs - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.time_between_poll_avg - description: The average delay between invocations of poll(). - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.consumer.time_between_poll_max - description: The max delay between invocations of poll(). - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.batch_size_avg - description: The average number of bytes sent per partition per-request. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.batch_size_max - description: The max number of bytes sent per partition per-request. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.batch_split_rate - description: The average number of batch splits per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.batch_split_total - description: The total number of batch splits - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.buffer_available_bytes - description: The total amount of buffer memory that is not being used (either - unallocated or in the free list). - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.buffer_exhausted_rate - description: The average per-second number of record sends that are dropped - due to buffer exhaustion - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.buffer_exhausted_total - description: The total number of record sends that are dropped due to buffer - exhaustion - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.buffer_total_bytes - description: The maximum amount of buffer memory the client can use (whether - or not it is currently used). - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.bufferpool_wait_ratio - description: The fraction of time an appender waits for space allocation. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.bufferpool_wait_time_total - description: The total time an appender waits for space allocation. - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.byte_rate - description: The average number of bytes sent per second for a topic. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.byte_total - description: The total number of bytes sent for a topic. - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.compression_rate - description: The average compression rate of record batches for a topic. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.compression_rate_avg - description: The average compression rate of record batches. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.connection_close_rate - description: The number of connections closed per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.connection_close_total - description: The total number of connections closed - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.connection_count - description: The current number of active connections. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.connection_creation_rate - description: The number of new connections established per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.connection_creation_total - description: The total number of new connections established - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.failed_authentication_rate - description: The number of connections with failed authentication per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.failed_authentication_total - description: The total number of connections with failed authentication - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.failed_reauthentication_rate - description: The number of failed re-authentication of connections per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.failed_reauthentication_total - description: The total number of failed re-authentication of connections - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.incoming_byte_rate - description: The number of bytes read off all sockets per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.incoming_byte_total - description: The total number of bytes read off all sockets - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.io_ratio - description: The fraction of time the I/O thread spent doing I/O - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.io_time_ns_avg - description: The average length of time for I/O per select call in nanoseconds. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.io_wait_ratio - description: The fraction of time the I/O thread spent waiting - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.io_wait_time_ns_avg - description: The average length of time the I/O thread spent waiting for a - socket ready for reads or writes in nanoseconds. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.io_waittime_total - description: The total time the I/O thread spent waiting - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.iotime_total - description: The total time the I/O thread spent doing I/O - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.metadata_age - description: The age in seconds of the current producer metadata being used. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.network_io_rate - description: The number of network operations (reads or writes) on all connections - per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.network_io_total - description: The total number of network operations (reads or writes) on all - connections - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.outgoing_byte_rate - description: The number of outgoing bytes sent to all servers per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.outgoing_byte_total - description: The total number of outgoing bytes sent to all servers - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.produce_throttle_time_avg - description: The average time in ms a request was throttled by a broker - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.produce_throttle_time_max - description: The maximum time in ms a request was throttled by a broker - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.record_error_rate - description: The average per-second number of record sends that resulted in - errors - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.record_error_total - description: The total number of record sends that resulted in errors - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.record_queue_time_avg - description: The average time in ms record batches spent in the send buffer. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.record_queue_time_max - description: The maximum time in ms record batches spent in the send buffer. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.record_retry_rate - description: The average per-second number of retried record sends - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.record_retry_total - description: The total number of retried record sends - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.record_send_rate - description: The average number of records sent per second. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.record_send_total - description: The total number of records sent. - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: topic - type: STRING - - name: kafka.producer.record_size_avg - description: The average record size - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.record_size_max - description: The maximum record size - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.records_per_request_avg - description: The average number of records per request. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.request_latency_avg - description: The average request latency in ms - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.request_latency_max - description: The maximum request latency in ms - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.request_rate - description: The number of requests sent per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.request_size_avg - description: The average size of requests sent. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.request_size_max - description: The maximum size of any request sent. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.request_total - description: The total number of requests sent - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.requests_in_flight - description: The current number of in-flight requests awaiting a response. - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.response_rate - description: The number of responses received per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.response_total - description: The total number of responses received - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: node-id - type: STRING - - name: kafka.producer.select_rate - description: The number of times the I/O layer checked for new I/O to perform - per second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.select_total - description: The total number of times the I/O layer checked for new I/O to - perform - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.successful_authentication_no_reauth_total - description: The total number of connections with successful authentication - where the client does not support re-authentication - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.successful_authentication_rate - description: The number of connections with successful authentication per - second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.successful_authentication_total - description: The total number of connections with successful authentication - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.successful_reauthentication_rate - description: The number of successful re-authentication of connections per - second - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.successful_reauthentication_total - description: The total number of successful re-authentication of connections - type: DOUBLE_SUM - unit: null - attributes: - - name: client-id - type: STRING - - name: kafka.producer.waiting_threads - description: The number of user threads blocked waiting for buffer memory - to enqueue their records - type: DOUBLE_GAUGE - unit: null - attributes: - - name: client-id - type: STRING - spans: - - span_kind: CONSUMER - attributes: - - name: kafka.record.queue_time_ms - type: LONG - - name: messaging.batch.message_count - type: LONG - - name: messaging.client_id - type: STRING - - name: messaging.destination.name - type: STRING - - name: messaging.destination.partition.id - type: STRING - - name: messaging.kafka.consumer.group - type: STRING - - name: messaging.kafka.message.offset - type: LONG - - name: messaging.message.body.size - type: LONG - - name: messaging.operation - type: STRING - - name: messaging.system - type: STRING - - span_kind: PRODUCER - attributes: - - name: messaging.client_id - type: STRING - - name: messaging.destination.name - type: STRING - - name: messaging.destination.partition.id - type: STRING - - name: messaging.kafka.message.offset - type: LONG - - name: messaging.operation - type: STRING - - name: messaging.system - type: STRING - - name: kafka-connect-2.6 - display_name: Apache Kafka Connect - description: This instrumentation enables messaging spans for Kafka Connect sink - tasks. - semantic_conventions: - - MESSAGING_SPANS - library_link: https://kafka.apache.org/documentation/#connect - source_path: instrumentation/kafka/kafka-connect-2.6 - scope: - name: io.opentelemetry.kafka-connect-2.6 - target_versions: - javaagent: - - org.apache.kafka:connect-api:[2.6.0,) - telemetry: - - when: default - spans: - - span_kind: CONSUMER - attributes: - - name: messaging.batch.message_count - type: LONG - - name: messaging.destination.name - type: STRING - - name: messaging.operation - type: STRING - - name: messaging.system - type: STRING - - name: thread.id - type: LONG - - name: thread.name - type: STRING - - name: kafka-streams-0.11 - display_name: Apache Kafka Streams - description: This instrumentation enables messaging spans for Kafka Streams processing. - semantic_conventions: - - MESSAGING_SPANS - library_link: https://kafka.apache.org/documentation/streams/ - source_path: instrumentation/kafka/kafka-streams-0.11 - scope: - name: io.opentelemetry.kafka-streams-0.11 - target_versions: - javaagent: - - org.apache.kafka:kafka-streams:[0.11.0.0,) - configurations: - - name: otel.instrumentation.kafka.experimental-span-attributes - description: Enables the capture of the experimental consumer attribute `kafka.record.queue_time_ms`. - type: boolean - default: false - - name: otel.instrumentation.messaging.experimental.capture-headers - description: A comma-separated list of header names to capture as span attributes. - type: list - default: '' - - name: otel.instrumentation.messaging.experimental.receive-telemetry.enabled - description: | - Enables experimental receive telemetry, which will cause consumers to start a new trace, with only a span link connecting it to the producer trace. - type: boolean - default: false - telemetry: - - when: default - spans: - - span_kind: CONSUMER - attributes: - - name: asdf - type: STRING - - name: messaging.client_id - type: STRING - - name: messaging.destination.name - type: STRING - - name: messaging.destination.partition.id - type: STRING - - name: messaging.kafka.consumer.group - type: STRING - - name: messaging.kafka.message.key - type: STRING - - name: messaging.kafka.message.offset - type: LONG - - name: messaging.message.body.size - type: LONG - - name: messaging.operation - type: STRING - - name: messaging.system - type: STRING - - when: otel.instrumentation.kafka.experimental-span-attributes=true - spans: - - span_kind: CONSUMER - attributes: - - name: asdf - type: STRING - - name: kafka.record.queue_time_ms - type: LONG - - name: messaging.client_id - type: STRING - - name: messaging.destination.name - type: STRING - - name: messaging.destination.partition.id - type: STRING - - name: messaging.kafka.consumer.group - type: STRING - - name: messaging.kafka.message.key - type: STRING - - name: messaging.kafka.message.offset - type: LONG - - name: messaging.message.body.size - type: LONG - - name: messaging.operation - type: STRING - - name: messaging.system - type: STRING - kotlinx: - - name: kotlinx-coroutines-1.0 - source_path: instrumentation/kotlinx-coroutines/kotlinx-coroutines-1.0 - scope: - name: io.opentelemetry.kotlinx-coroutines-1.0 - target_versions: - javaagent: - - org.jetbrains.kotlinx:kotlinx-coroutines-core-jvm:[1.3.9,) - - org.jetbrains.kotlinx:kotlinx-coroutines-core:[1.0.0,1.3.8) - - name: kotlinx-coroutines-flow-1.3 - source_path: instrumentation/kotlinx-coroutines/kotlinx-coroutines-flow-1.3 - scope: - name: io.opentelemetry.kotlinx-coroutines-flow-1.3 - target_versions: - javaagent: - - org.jetbrains.kotlinx:kotlinx-coroutines-core:[1.3.0,1.3.8) - - org.jetbrains.kotlinx:kotlinx-coroutines-core-jvm:[1.3.9,) - ktor: - - name: ktor-1.0 - source_path: instrumentation/ktor/ktor-1.0 - scope: - name: io.opentelemetry.ktor-1.0 - schema_url: https://opentelemetry.io/schemas/1.37.0 - target_versions: - library: - - io.ktor:ktor-server-core:[1.0.0,1.+) - telemetry: - - when: default - metrics: - - name: http.server.request.duration - description: Duration of HTTP server requests. - type: HISTOGRAM - unit: s - attributes: - - name: http.request.method - type: STRING - - name: http.response.status_code - type: LONG - - name: http.route - type: STRING - - name: network.protocol.version - type: STRING - - name: url.scheme - type: STRING - spans: - - span_kind: CONSUMER - attributes: - - name: client.address - type: STRING - - name: http.request.method - type: STRING - - name: http.response.status_code - type: LONG - - name: network.peer.address - type: STRING - - name: network.protocol.version - type: STRING - - name: server.address - type: STRING - - name: server.port - type: LONG - - name: url.path - type: STRING - - name: url.query - type: STRING - - name: url.scheme - type: STRING - - name: user_agent.original - type: STRING - - span_kind: SERVER - attributes: - - name: client.address - type: STRING - - name: error.type - type: STRING - - name: http.request.method - type: STRING - - name: http.request.method_original - type: STRING - - name: http.response.status_code - type: LONG - - name: http.route - type: STRING - - name: network.peer.address - type: STRING - - name: network.protocol.version - type: STRING - - name: server.address - type: STRING - - name: server.port - type: LONG - - name: url.path - type: STRING - - name: url.query - type: STRING - - name: url.scheme - type: STRING - - name: user_agent.original - type: STRING - - name: ktor-2.0 - source_path: instrumentation/ktor/ktor-2.0 - scope: - name: io.opentelemetry.ktor-2.0 - schema_url: https://opentelemetry.io/schemas/1.37.0 - target_versions: - javaagent: - - io.ktor:ktor-client-core:[2.0.0,3.0.0) - - io.ktor:ktor-server-core:[2.0.0,3.0.0) - library: - - io.ktor:ktor-client-core:[2.0.0,2.+) - - io.ktor:ktor-server-core:[2.0.0,2.+) - telemetry: - - when: default - 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: http.server.request.duration - description: Duration of HTTP server requests. - type: HISTOGRAM - unit: s - attributes: - - name: http.request.method - type: STRING - - name: http.response.status_code - type: LONG - - name: http.route - type: STRING - - name: network.protocol.version - type: STRING - - name: url.scheme - type: STRING spans: - - span_kind: CLIENT + - span_kind: CONSUMER attributes: - - name: error.type - type: STRING - - name: http.request.method - type: STRING - - name: http.request.method_original - type: STRING - - name: http.request.resend_count + - name: kafka.record.queue_time_ms type: LONG - - name: http.response.status_code + - name: messaging.batch.message_count type: LONG - - name: network.protocol.version - type: STRING - - name: server.address + - name: messaging.client_id type: STRING - - name: server.port - type: LONG - - name: url.full + - name: messaging.destination.name type: STRING - - span_kind: CONSUMER - attributes: - - name: client.address + - name: messaging.destination.partition.id type: STRING - - name: http.request.method + - name: messaging.kafka.consumer.group type: STRING - - name: http.response.status_code + - name: messaging.kafka.message.offset type: LONG - - name: network.protocol.version - type: STRING - - name: server.address - type: STRING - - name: server.port + - name: messaging.message.body.size type: LONG - - name: url.path - type: STRING - - name: url.query - type: STRING - - name: url.scheme + - name: messaging.operation type: STRING - - name: user_agent.original + - name: messaging.system type: STRING - - span_kind: SERVER + - span_kind: PRODUCER attributes: - - name: client.address - type: STRING - - name: error.type - type: STRING - - name: http.request.method - type: STRING - - name: http.request.method_original - type: STRING - - name: http.response.status_code - type: LONG - - name: http.route + - name: messaging.client_id type: STRING - - name: network.protocol.version + - name: messaging.destination.name type: STRING - - name: server.address + - name: messaging.destination.partition.id type: STRING - - name: server.port + - name: messaging.kafka.message.offset type: LONG - - name: url.path - type: STRING - - name: url.query - type: STRING - - name: url.scheme + - name: messaging.operation type: STRING - - name: user_agent.original + - name: messaging.system type: STRING - - name: ktor-3.0 - source_path: instrumentation/ktor/ktor-3.0 + - name: kafka-connect-2.6 + display_name: Apache Kafka Connect + description: This instrumentation enables messaging spans for Kafka Connect sink + tasks. + semantic_conventions: + - MESSAGING_SPANS + library_link: https://kafka.apache.org/documentation/#connect + source_path: instrumentation/kafka/kafka-connect-2.6 scope: - name: io.opentelemetry.ktor-3.0 - schema_url: https://opentelemetry.io/schemas/1.37.0 + name: io.opentelemetry.kafka-connect-2.6 target_versions: javaagent: - - io.ktor:ktor-server-core:[3.0.0,) - - io.ktor:ktor-client-core:[3.0.0,) - library: - - io.ktor:ktor-server-core:3.0.0 - - io.ktor:ktor-client-core:3.0.0 + - org.apache.kafka:connect-api:[2.6.0,) telemetry: - when: default - metrics: - - name: http.client.request.duration - description: Duration of HTTP client requests. - type: HISTOGRAM - unit: s + spans: + - span_kind: CONSUMER attributes: - - name: http.request.method - type: STRING - - name: http.response.status_code + - name: messaging.batch.message_count type: LONG - - name: network.protocol.version + - name: messaging.destination.name type: STRING - - name: server.address + - name: messaging.operation type: STRING - - name: server.port - type: LONG - - name: http.server.request.duration - description: Duration of HTTP server requests. - type: HISTOGRAM - unit: s - attributes: - - name: http.request.method + - name: messaging.system type: STRING - - name: http.response.status_code + - name: thread.id type: LONG - - name: http.route - type: STRING - - name: network.protocol.version - type: STRING - - name: url.scheme + - name: thread.name type: STRING + - name: kafka-streams-0.11 + display_name: Apache Kafka Streams + description: This instrumentation enables messaging spans for Kafka Streams processing. + semantic_conventions: + - MESSAGING_SPANS + library_link: https://kafka.apache.org/documentation/streams/ + source_path: instrumentation/kafka/kafka-streams-0.11 + scope: + name: io.opentelemetry.kafka-streams-0.11 + target_versions: + javaagent: + - org.apache.kafka:kafka-streams:[0.11.0.0,) + configurations: + - name: otel.instrumentation.kafka.experimental-span-attributes + description: Enables the capture of the experimental consumer attribute `kafka.record.queue_time_ms`. + type: boolean + default: false + - name: otel.instrumentation.messaging.experimental.capture-headers + description: A comma-separated list of header names to capture as span attributes. + type: list + default: '' + - name: otel.instrumentation.messaging.experimental.receive-telemetry.enabled + description: | + Enables experimental receive telemetry, which will cause consumers to start a new trace, with only a span link connecting it to the producer trace. + type: boolean + default: false + telemetry: + - when: default spans: - - span_kind: CLIENT + - span_kind: CONSUMER attributes: - - name: error.type - type: STRING - - name: http.request.method + - name: asdf type: STRING - - name: http.request.method_original + - name: messaging.client_id type: STRING - - name: http.request.resend_count - type: LONG - - name: http.response.status_code - type: LONG - - name: network.protocol.version + - name: messaging.destination.name type: STRING - - name: server.address + - name: messaging.destination.partition.id type: STRING - - name: server.port - type: LONG - - name: url.full + - name: messaging.kafka.consumer.group type: STRING - - span_kind: SERVER - attributes: - - name: client.address + - name: messaging.kafka.message.key type: STRING - - name: error.type + - name: messaging.kafka.message.offset + type: LONG + - name: messaging.message.body.size + type: LONG + - name: messaging.operation type: STRING - - name: http.request.method + - name: messaging.system type: STRING - - name: http.request.method_original + - when: otel.instrumentation.kafka.experimental-span-attributes=true + spans: + - span_kind: CONSUMER + attributes: + - name: asdf type: STRING - - name: http.response.status_code + - name: kafka.record.queue_time_ms type: LONG - - name: http.route + - name: messaging.client_id type: STRING - - name: network.protocol.version + - name: messaging.destination.name type: STRING - - name: server.address + - name: messaging.destination.partition.id type: STRING - - name: server.port - type: LONG - - name: url.path + - name: messaging.kafka.consumer.group type: STRING - - name: url.query + - name: messaging.kafka.message.key type: STRING - - name: url.scheme + - name: messaging.kafka.message.offset + type: LONG + - name: messaging.message.body.size + type: LONG + - name: messaging.operation type: STRING - - name: user_agent.original + - name: messaging.system type: STRING + kotlinx: + - name: kotlinx-coroutines-1.0 + source_path: instrumentation/kotlinx-coroutines/kotlinx-coroutines-1.0 + scope: + name: io.opentelemetry.kotlinx-coroutines-1.0 + target_versions: + javaagent: + - org.jetbrains.kotlinx:kotlinx-coroutines-core-jvm:[1.3.9,) + - org.jetbrains.kotlinx:kotlinx-coroutines-core:[1.0.0,1.3.8) + - name: kotlinx-coroutines-flow-1.3 + source_path: instrumentation/kotlinx-coroutines/kotlinx-coroutines-flow-1.3 + scope: + name: io.opentelemetry.kotlinx-coroutines-flow-1.3 + target_versions: + javaagent: + - org.jetbrains.kotlinx:kotlinx-coroutines-core:[1.3.0,1.3.8) + - org.jetbrains.kotlinx:kotlinx-coroutines-core-jvm:[1.3.9,) + ktor: + - name: ktor-1.0 + source_path: instrumentation/ktor/ktor-1.0 + scope: + name: io.opentelemetry.ktor-1.0 + target_versions: + library: + - io.ktor:ktor-server-core:[1.0.0,1.+) + - name: ktor-2.0 + source_path: instrumentation/ktor/ktor-2.0 + scope: + name: io.opentelemetry.ktor-2.0 + target_versions: + javaagent: + - io.ktor:ktor-client-core:[2.0.0,3.0.0) + - io.ktor:ktor-server-core:[2.0.0,3.0.0) + library: + - io.ktor:ktor-client-core:[2.0.0,2.+) + - io.ktor:ktor-server-core:[2.0.0,2.+) + - name: ktor-3.0 + source_path: instrumentation/ktor/ktor-3.0 + scope: + name: io.opentelemetry.ktor-3.0 + target_versions: + javaagent: + - io.ktor:ktor-server-core:[3.0.0,) + - io.ktor:ktor-client-core:[3.0.0,) + library: + - io.ktor:ktor-server-core:3.0.0 + - io.ktor:ktor-client-core:3.0.0 kubernetes: - name: kubernetes-client-7.0 source_path: instrumentation/kubernetes-client-7.0 diff --git a/instrumentation/kafka/kafka-clients/kafka-clients-2.6/library/src/test/java/io/opentelemetry/instrumentation/kafkaclients/v2_6/InterceptorsTest.java b/instrumentation/kafka/kafka-clients/kafka-clients-2.6/library/src/test/java/io/opentelemetry/instrumentation/kafkaclients/v2_6/InterceptorsTest.java index d96b4d951295..3e42dce07622 100644 --- a/instrumentation/kafka/kafka-clients/kafka-clients-2.6/library/src/test/java/io/opentelemetry/instrumentation/kafkaclients/v2_6/InterceptorsTest.java +++ b/instrumentation/kafka/kafka-clients/kafka-clients-2.6/library/src/test/java/io/opentelemetry/instrumentation/kafkaclients/v2_6/InterceptorsTest.java @@ -25,7 +25,6 @@ import io.opentelemetry.sdk.trace.data.LinkData; import java.nio.charset.StandardCharsets; import java.util.concurrent.atomic.AtomicReference; -import org.assertj.core.api.AbstractIterableAssert; import org.assertj.core.api.AbstractLongAssert; import org.assertj.core.api.AbstractStringAssert; @@ -126,10 +125,5 @@ void assertTraces() { trace.hasSpansSatisfyingExactly( span -> span.hasName("producer callback").hasKind(SpanKind.INTERNAL).hasNoParent())); - - testing.waitAndAssertMetrics( - "io.opentelemetry.kafka-clients-2.6", - "kafka.producer.record_send_total", - AbstractIterableAssert::isNotEmpty); } }