This documentation has an index for AI agents at /llms.txt. A Markdown version of this page is available at https://explorer.opentelemetry.io/java-agent/instrumentation/vertx-kafka-client-3.6.md.

Vert.x Kafka Client

OpenTelemetry Java agent instrumentation

This instrumentation enables messaging spans for Kafka consumers using the Vert.x Kafka Client library.

  • Name: vertx-kafka-client-3.6
  • Scope: io.opentelemetry.vertx-kafka-client-3.6
  • Target versions: io.vertx:vertx-kafka-client:[3.5.1,)
  • Library: https://vertx.io/docs/vertx-kafka-client/java/

Telemetry

When otel.instrumentation.common.messaging.experimental.receive-telemetry.enabled=true

Spans

Span kindAttributes
CONSUMERmessaging.batch.message_count (LONG), messaging.client_id (STRING), messaging.destination.name (STRING), messaging.destination.partition.id (STRING), messaging.kafka.cluster.id (STRING), messaging.kafka.message.key (STRING), messaging.kafka.message.offset (LONG), messaging.message.body.size (LONG), messaging.operation (STRING), messaging.system (STRING)

When otel.instrumentation.common.messaging.experimental.receive-telemetry.enabled=true,otel.instrumentation.kafka.experimental-span-attributes=true

Spans

Span kindAttributes
CONSUMERkafka.record.queue_time_ms (LONG), messaging.batch.message_count (LONG), messaging.client_id (STRING), messaging.destination.name (STRING), messaging.destination.partition.id (STRING), messaging.kafka.cluster.id (STRING), messaging.kafka.message.key (STRING), messaging.kafka.message.offset (LONG), messaging.message.body.size (LONG), messaging.operation (STRING), messaging.system (STRING)

When otel.semconv-stability.preview=messaging

Metrics

MetricInstrumentTypeUnitDescription
messaging.process.durationhistogramHISTOGRAMsDuration of processing operation.
MetricAttributes
messaging.process.durationmessaging.destination.name (STRING), messaging.destination.partition.id (STRING), messaging.operation.name (STRING), messaging.system (STRING)

Spans

Span kindAttributes
CONSUMERerror.type (STRING), messaging.batch.message_count (LONG), messaging.client.id (STRING), messaging.destination.name (STRING), messaging.destination.partition.id (STRING), messaging.kafka.cluster.id (STRING), messaging.kafka.message.key (STRING), messaging.kafka.offset (LONG), messaging.operation.name (STRING), messaging.operation.type (STRING), messaging.system (STRING)

Configuration

OptionTypeDefaultDescription
otel.instrumentation.messaging.experimental.capture-headerslistDeprecated: use otel.instrumentation.common.messaging.headers.included instead. Ignored without a warning under v3-preview; may be removed in a later minor release and will be removed no later than 3.0. A comma-separated list of header names to capture as span attributes. It does not support glob patterns: an entry containing * or ? is ignored with a warning, and every other entry is matched as a literal header name.
otel.instrumentation.messaging.experimental.headers.excludedlistDeprecated: use otel.instrumentation.common.messaging.headers.excluded instead. Ignored without a warning under v3-preview; may be removed in a later minor release and will be removed no later than 3.0.
otel.instrumentation.messaging.experimental.headers.includedlistDeprecated: use otel.instrumentation.common.messaging.headers.included instead. Ignored without a warning under v3-preview; may be removed in a later minor release and will be removed no later than 3.0.
otel.instrumentation.messaging.experimental.receive-telemetry.enabledbooleanfalseDeprecated: use otel.instrumentation.common.messaging.experimental.receive-telemetry.enabled instead. It may be removed in the next minor release.
otel.instrumentation.common.messaging.headers.excludedlistA comma-separated list of case-sensitive message header name glob patterns to exclude from span attributes. ? matches one character and * matches zero or more characters. Excluded patterns take precedence over included patterns. An absent or empty selector captures no headers; an exclude-only selector captures every header not excluded, which may expose sensitive information.
otel.instrumentation.common.messaging.headers.includedlistA comma-separated list of case-sensitive message header name glob patterns to capture as span attributes. ? matches one character and * matches zero or more characters. Excluded patterns take precedence over included patterns. An absent or empty selector captures no headers; an exclude-only selector captures every header not excluded.
otel.instrumentation.common.messaging.experimental.receive-telemetry.enabledbooleanfalseEnables experimental receive telemetry, which will cause consumers to start a new trace, with only a span link connecting it to the producer trace.
otel.instrumentation.kafka.experimental-span-attributesbooleanfalseEnables the capture of the experimental consumer attributes kafka.record.queue_time_ms and messaging.kafka.bootstrap.servers.
otel.instrumentation.kafka.producer-propagation.enabledbooleantrueEnable context propagation for Kafka message producers.

Data

  • JSON (latest): /data/javaagent/instrumentations/vertx-kafka-client-3.6/latest.json
  • JSON (pinned): /data/javaagent/instrumentations/vertx-kafka-client-3.6/vertx-kafka-client-3.6-2cfb7a8b4c02.json
  • Explore: /java-agent/instrumentation/vertx-kafka-client-3.6