Awsemf Exporter
contrib
Maintainers: @Aneurysm9, @mxiamxia
Source: opentelemetry-collector-contrib
Supported Telemetry
Overview
This exporter converts OpenTelemetry metrics to AWS CloudWatch Embedded Metric Format(EMF) and then sends them directly to CloudWatch Logs using the PutLogEvents API.Data Conversion
Convert OpenTelemetryInt64DataPoints, DoubleDataPoints, SummaryDataPoints metrics datapoints into
CloudWatch EMF structured log formats and send it to CloudWatch. Logs and Metrics will be displayed in
CloudWatch console. NaN, Inf values are not supported by CloudWatch EMF and will be dropped by the exporter.
Exporter Configuration
The following exporter configuration parameters are supported.metric_declaration
A metric_declaration section characterizes a rule to be used to set dimensions for exported metrics, filtered by the incoming metrics’ labels and metric names.label_matcher
A label_matcher section defines a matching rule against the labels of the incoming metric. Only metrics that match the rules will be used by the surroundingmetric_declaration.
metric_descriptor
A metric descriptor section allows the schema of a metric to be overwritten before sending out to the CloudWatch backend service. Currently, we only support unit override.AWS Credential Configuration
This exporter follows default credential resolution for the aws-sdk-go. Follow the guidelines for the credential configuration.Metric Attributes
By setting attributes on your metrics you can change how individual metrics are sent to CloudWatch. Attributes can be set in code or using components like the Attribute Processor. The AWS EMF Exporter will interpret the following metric attributes to change how it publishes metrics to CloudWatch:Configuration Examples
Resource Attributes to Metric Labels
Theresource_to_telemetry_conversion option can be used to convert resource attributes to metric labels. By default, this option is disabled.
You can specify included and excluded wildcard pattern lists to match attribute keys.
Legacy options enabled and exclude_service_attributes are deprecated (and can be disabled via the exporter.awsemf.DisableLegacyResourceToTelemetryConversion feature gate). When migrating from enabled: true, the equivalent configuration is setting included: ["*"]. See the config example below:
Metric Declaration
The following is an example of how to usemetric_declaration to select what metrics should be exported.
Configuration
Example Configuration
Last generated: 2026-10-05