Back to Skywalking

OpenTelemetry Metrics Format

docs/en/setup/backend/opentelemetry-receiver.md

10.4.011.1 KB
Original Source

OpenTelemetry Metrics Format

The OpenTelemetry receiver supports ingesting agent metrics by meter-system. The OAP can load the configuration at bootstrap. If the new configuration is not well-formed, the OAP may fail to start up. The files are located at $CLASSPATH/otel-rules.

Supported handlers:

Notice: Set SW_OTEL_RECEIVER=default through system environment or change receiver-otel/selector=${SW_OTEL_RECEIVER:default} to activate the OpenTelemetry receiver.

The rule file should be in YAML format, defined by the scheme described in MAL. Note: receiver-otel only supports the group, defaultMetricLevel, and metricsRules nodes of the scheme due to its push mode.

To activate the otlp handler and relevant rules of istio:

yaml
receiver-otel:
  selector: ${SW_OTEL_RECEIVER:default}
  default:
    enabledHandlers: ${SW_OTEL_RECEIVER_ENABLED_HANDLERS:"otlp-metrics"}
    enabledOtelMetricsRules: ${SW_OTEL_RECEIVER_ENABLED_OTEL_METRICS_RULES:"istio-controlplane"}

The receiver adds label with key node_identifier_host_name to the collected data samples, and its value is from net.host.name (or host.name for some OTLP versions) resource attributes defined in OpenTelemetry proto, for identification of the metric data.

Label name conversion: Dots (.) in attribute key names are converted to underscores (_) for both resource attributes and data point (metric-level) attributes. For example, gen_ai.token.type becomes gen_ai_token_type in MAL rules. Metric names also undergo the same conversion (e.g., gen_ai.client.token.usage becomes gen_ai_client_token_usage).

Fallback label mappings: The following resource attributes are copied to alternative label names if the target does not already exist. These are fallback-only — if the target label is already present in the resource attributes, the fallback is skipped.

SourceTargetNotes
service.namejob_nameThe OTel Collector Prometheus Receiver automatically converts the Prometheus job label to service.name. This fallback ensures it is available as job_name for MAL rule filtering.
net.host.namenode_identifier_host_nameLegacy: used by VM/Windows MAL rules
host.namenode_identifier_host_nameLegacy: used by VM/Windows MAL rules

When job_name is set explicitly in OTEL_RESOURCE_ATTRIBUTES (e.g., by Envoy AI Gateway), it takes precedence and the service.name fallback is skipped.

Note: The net.host.name and host.name mappings are legacy. New integrations should use the natural dot-to-underscore conversion (e.g., host.namehost_name in MAL rules).

DescriptionConfiguration FileData Source
Metrics of Istio Control Planeotel-rules/istio-controlplane.yamlIstio Control Plane -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of SkyWalking OAP server itselfotel-rules/oap.yamlSkyWalking OAP Server(SelfObservability) -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Linux OSotel-rules/vm.yamlprometheus/node_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Windows OSotel-rules/windows.yamlprometheus-community/windows_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of K8s clusterotel-rules/k8s/k8s-cluster.yamlK8s kube-state-metrics -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of K8s clusterotel-rules/k8s/k8s-node.yamlcAdvisor & K8s kube-state-metrics -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of K8s clusterotel-rules/k8s/k8s-service.yamlcAdvisor & K8s kube-state-metrics -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of MYSQLotel-rules/mysql/mysql-instance.yamlprometheus/mysqld_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of MYSQLotel-rules/mysql/mysql-service.yamlprometheus/mysqld_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of PostgreSQLotel-rules/postgresql/postgresql-instance.yamlprometheus-community/postgres_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of PostgreSQLotel-rules/postgresql/postgresql-service.yamlprometheus-community/postgres_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Apache APISIXotel-rules/apisix.yamlapisix prometheus plugin -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of AWS Cloud EKSotel-rules/aws-eks/eks-cluster.yamlAWS Container Insights Receiver -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of AWS Cloud EKSotel-rules/aws-eks/eks-service.yamlAWS Container Insights Receiver -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of AWS Cloud EKSotel-rules/aws-eks/eks-node.yamlAWS Container Insights Receiver -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Elasticsearchotel-rules/elasticsearch/elasticsearch-cluster.yamlprometheus-community/elasticsearch_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Elasticsearchotel-rules/elasticsearch/elasticsearch-index.yamlprometheus-community/elasticsearch_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Elasticsearchotel-rules/elasticsearch/elasticsearch-node.yamlprometheus-community/elasticsearch_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Redisotel-rules/redis/redis-service.yamloliver006/redis_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Redisotel-rules/redis/redis-instance.yamloliver006/redis_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of RabbitMQotel-rules/rabbitmq/rabbitmq-cluster.yamlrabbitmq-prometheus -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of RabbitMQotel-rules/rabbitmq/rabbitmq-node.yamlrabbitmq-prometheus -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of MongoDBotel-rules/mongodb/mongodb-cluster.yamlpercona/mongodb_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of MongoDBotel-rules/mongodb/mongodb-node.yamlpercona/mongodb_exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Kafkaotel-rules/kafka/kafka-cluster.yamlprometheus/jmx_exporter/jmx_prometheus_javaagent -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Kafkaotel-rules/kafka/kafka-broker.yamlprometheus/jmx_exporter/jmx_prometheus_javaagent -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of ClickHouseotel-rules/clickhouse/clickhouse-instance.yamlClickHouse(embedded prometheus endpoint) -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of ClickHouseotel-rules/clickhouse/clickhouse-service.yamlClickHouse(embedded prometheus endpoint) -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of RocketMQotel-rules/rocketmq/rocketmq-cluster.yamlrocketmq-exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of RocketMQotel-rules/rocketmq/rocketmq-broker.yamlrocketmq-exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of RocketMQotel-rules/rocketmq/rocketmq-topic.yamlrocketmq-exporter -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Flinkotel-rules/flink/flink-jobManager.yamlflink jobManager -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Flinkotel-rules/flink/flink-taskManager.yamlflink taskManager -> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of Flinkotel-rules/flink/flink-job.yamlflink jobManager & flink taskManager-> OpenTelemetry Collector -- OTLP exporter --> SkyWalking OAP Server
Metrics of BanyanDBotel-rules/banyandb/banyandb-instance.yamlBanyanDB(embedded prometheus endpoint) -> OpenTelemetry Collector – OTLP exporter –> SkyWalking OAP Server
Metrics of BanyanDBotel-rules/banyandb/banyandb-service.yamlBanyanDB(embedded prometheus endpoint) -> OpenTelemetry Collector – OTLP exporter –> SkyWalking OAP Server