Skip to content

[extension/healthcheck] Add Component Event Attributes to serialized output #43606

@rogercoll

Description

@rogercoll

Component(s)

extension/healthcheckv2

Is your feature request related to a problem? Please describe.

An attributes map has been added to the core Collector Component Status Event — see PR #13348

Currently, the healthcheck extension’s status endpoint does not expose these attributes. Adding support for them would be valuable for services that depend on this endpoint to access additional context or metadata.

For instance, there are plans to start populating these attributes in the receiver creator — see issue #39053

Describe the solution you'd like

Display attributes in the /health/status?verbose endpoint:

{
  "start_time": "2025-10-16T17:56:10.795226826+02:00",
  "healthy": true,
  "status": "StatusRecoverableError",
  "status_time": "2025-10-16T17:56:11.820542393+02:00",
  "attributes": {
     "error_msg": "not enough permissions to read cpu data",
     "scrapers": ["cpu", "memory", "network"]
  },
  "components": {
    "extensions": {
      "healthy": true,
      "status": "StatusOK",
      "status_time": "2025-10-16T17:56:10.801960179+02:00",
      "attributes": {},
      "components": {
        "extension:healthcheckv2": {
          "healthy": true,
          "status": "StatusOK",
          "status_time": "2025-10-16T17:56:10.801960179+02:00",
          "attributes": {}
        }
      }
    },
    "pipeline:metrics/1": {
      "healthy": true,
      "status": "StatusRecoverableError",
      "status_time": "2025-10-16T17:56:11.820542393+02:00",
      "attributes": {
        "error_msg": "not enough permissions to read cpu data",
        "scrapers": ["cpu", "memory", "network"]
      },
      "components": {
        "exporter:debug": {
          "healthy": true,
          "status": "StatusOK",
          "status_time": "2025-10-16T17:56:10.808017787+02:00",
          "attributes": {}
        },
        "receiver:hostmetrics/producer": {
          "healthy": true,
          "status": "StatusRecoverableError",
          "status_time": "2025-10-16T17:56:11.820542393+02:00",
          "attributes": {
            "error_msg": "not enough permissions to read cpu data",
            "scrapers": ["cpu", "memory", "network"]
          }
        }
      }
    }
  }
}

Describe alternatives you've considered

No response

Additional context

No response

Tip

React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it. Learn more here.

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