Skip to content

[BUG] JMX and OpenMetrics metrics not tagged with pod_name #38865

@mjiderhamn

Description

@mjiderhamn

Agent Environment

Agent 7.67.0 - Commit: bdf863c - Serialization version: v5.0.150 - Go version: go1.23.9

Describe what happened:
Configured JMX and OpenMetrics collection in a Kubernetes via autodiscovery. Metrics are reported properly and tagged with metadata such as kube_cluster_name and image_name, but not pod_name like Kubernetes metrics.

Describe what you expected:
JMX and OpenMetrics to be tagged with pod_name (or at least some tag to identify the pod).

Steps to reproduce the issue:
Collect JMX or OpenMetrics metrics.

Additional environment details (Operating System, Cloud provider, etc):

Can likely be mitigated with a small change in extractTagsFromPodEntity() at /comp/core/tagger/collectors/workloadmeta_extract.go#L332

Use case

Since multiple pods may be scheduled to run on the same node, host is not enough to identify a single pod. It is therefore not possible out of the box to create monitors triggering on for example a large percentage of the maximum heap memory being used within a single pod/container.

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