Skip to content

[exporter/elasticsearch] data loss due to incorrect metrics grouping #37898

Closed
@carsonip

Description

@carsonip

Component(s)

exporter/elasticsearch

What happened?

Description

Metrics: in OTel mapping mode, data points are not grouped properly and may result in validation error within ES exporter. Regression from #37509 released in 0.119.0

Steps to Reproduce

create 2 data points from different resources but ends up in the same index

Expected Result

No error

Actual Result

validation error

2025-02-13T08:14:29.974Z	warn	[email protected]/exporter.go:340	validation errors	{"kind": "exporter", "data_type": "metrics", "name": "elasticsearch/otel", "error": "metric with name 'k8s.node.condition_ready' has already been serialized in document with timestamp 2025-02-13T08:14:29.902238381Z\nmetric with name 'k8s.node.condition_memory_pressure' has already been serialized in document with timestamp 2025-02-13T08:14:29.902238381Z\nmetric with name 'k8s.node.condition_ready' has already been serialized in document with timestamp 2025-02-13T08:14:29.902238381Z\n

Collector version

0.119.0

Environment information

Environment

OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")

OpenTelemetry Collector configuration

Log output

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions