Micrometer Observation Documentation

Observability - Metrics

Below you can find a list of all metrics declared by this project.

Listener Observation

Observation for Apache Kafka listeners.

Metric name spring.kafka.listener (defined by convention class KafkaListenerObservation$DefaultKafkaListenerObservationConvention). Type timer.

Metric name spring.kafka.listener.active (defined by convention class KafkaListenerObservation$DefaultKafkaListenerObservationConvention). Type long task timer.

KeyValues that are added after starting the Observation might be missing from the *.active metrics.
Micrometer internally uses nanoseconds for the baseunit. However, each backend determines the actual baseunit. (i.e. Prometheus uses seconds)

Name of the enclosing class KafkaListenerObservation.

Table 1. Low cardinality Keys

Name

Description

messaging.kafka.consumer.group (required)

Messaging the consumer group.

messaging.operation (required)

Messaging operation.

messaging.source.kind (required)

Messaging source kind.

messaging.source.name (required)

Messaging source name.

messaging.system (required)

Messaging system.

spring.kafka.listener.id (required)

Listener id (or listener container bean name).

Template Observation

Observation for KafkaTemplates.

Metric name spring.kafka.template (defined by convention class KafkaTemplateObservation$DefaultKafkaTemplateObservationConvention). Type timer.

Metric name spring.kafka.template.active (defined by convention class KafkaTemplateObservation$DefaultKafkaTemplateObservationConvention). Type long task timer.

KeyValues that are added after starting the Observation might be missing from the *.active metrics.
Micrometer internally uses nanoseconds for the baseunit. However, each backend determines the actual baseunit. (i.e. Prometheus uses seconds)

Name of the enclosing class KafkaTemplateObservation.

Table 2. Low cardinality Keys

Name

Description

messaging.destination.kind (required)

Messaging destination kind.

messaging.destination.name (required)

Messaging destination name.

messaging.operation (required)

Messaging operation.

messaging.system (required)

Messaging system.

spring.kafka.template.name (required)

Bean name of the template.

Observability - Spans

Below you can find a list of all spans declared by this project.

Listener Observation Span

Observation for Apache Kafka listeners.

Span name spring.kafka.listener (defined by convention class KafkaListenerObservation$DefaultKafkaListenerObservationConvention).

Name of the enclosing class KafkaListenerObservation.

Table 3. Tag Keys

Name

Description

messaging.consumer.id (required)

Messaging consumer id (consumer group and client id).

messaging.kafka.client_id (required)

Messaging client id.

messaging.kafka.consumer.group (required)

Messaging the consumer group.

messaging.kafka.message.offset (required)

Messaging message offset.

messaging.kafka.source.partition (required)

Messaging partition.

messaging.operation (required)

Messaging operation.

messaging.source.kind (required)

Messaging source kind.

messaging.source.name (required)

Messaging source name.

messaging.system (required)

Messaging system.

spring.kafka.listener.id (required)

Listener id (or listener container bean name).

Template Observation Span

Observation for KafkaTemplates.

Span name spring.kafka.template (defined by convention class KafkaTemplateObservation$DefaultKafkaTemplateObservationConvention).

Name of the enclosing class KafkaTemplateObservation.

Table 4. Tag Keys

Name

Description

messaging.destination.kind (required)

Messaging destination kind.

messaging.destination.name (required)

Messaging destination name.

messaging.operation (required)

Messaging operation.

messaging.system (required)

Messaging system.

spring.kafka.template.name (required)

Bean name of the template.

Observability - Conventions

Below you can find a list of all GlobalObservationConvention and ObservationConvention declared by this project.

Table 5. ObservationConvention implementations

ObservationConvention Class Name

Applicable ObservationContext Class Name

KafkaListenerObservation

KafkaRecordReceiverContext

KafkaListenerObservation.DefaultKafkaListenerObservationConvention

KafkaRecordReceiverContext

KafkaListenerObservationConvention

KafkaRecordReceiverContext

KafkaTemplateObservation

KafkaRecordSenderContext

KafkaTemplateObservation.DefaultKafkaTemplateObservationConvention

KafkaRecordSenderContext

KafkaTemplateObservationConvention

KafkaRecordSenderContext