Skip to content

[prometheus-cloudwatch-exporter] add commonLabels support#6715

Open
firasmosbehi wants to merge 1 commit into
prometheus-community:mainfrom
firasmosbehi:codex/6247-cloudwatch-common-labels
Open

[prometheus-cloudwatch-exporter] add commonLabels support#6715
firasmosbehi wants to merge 1 commit into
prometheus-community:mainfrom
firasmosbehi:codex/6247-cloudwatch-common-labels

Conversation

@firasmosbehi

Copy link
Copy Markdown
Contributor

Summary

This PR adds commonLabels support to prometheus-cloudwatch-exporter resources and addresses #6247.

Problem

The chart exposes resource-specific label knobs (service.labels, deployment.labels, etc.) but lacks a global/common label mechanism. Users wanting organization-wide labels on all chart resources must duplicate labels per-resource or patch rendered manifests.

Root cause

No top-level value exists to inject shared labels into metadata across all templates.

Fix

  • Added commonLabels: {} to values.yaml.
  • Wired commonLabels into metadata labels for all chart-rendered resources.
  • Included commonLabels in deployment pod template labels.
  • Ensured PrometheusRule and ServiceMonitor metadata labels include commonLabels even when chart-specific label maps are empty.
  • Bumped chart version from 0.28.1 to 0.28.2.

Validation

  • helm lint charts/prometheus-cloudwatch-exporter
  • helm template test charts/prometheus-cloudwatch-exporter --set commonLabels.team=platform --set serviceMonitor.enabled=true --set prometheusRule.enabled=true
  • Verified repeated team: platform labels across rendered resources.

Compatibility

Backward compatible: commonLabels defaults to {} and does not affect existing installs unless explicitly set.

Signed-off-by: Firas Mosbehi <firas.mosbehi@insat.ucar.tn>
@firasmosbehi firasmosbehi changed the title [codex] [prometheus-cloudwatch-exporter] add commonLabels support [prometheus-cloudwatch-exporter] add commonLabels support Mar 6, 2026
@firasmosbehi firasmosbehi changed the title [prometheus-cloudwatch-exporter] add commonLabels support [codex] [prometheus-cloudwatch-exporter] add commonLabels support Mar 6, 2026
@firasmosbehi firasmosbehi marked this pull request as ready for review March 6, 2026 09:44
@firasmosbehi firasmosbehi changed the title [codex] [prometheus-cloudwatch-exporter] add commonLabels support [prometheus-cloudwatch-exporter] add commonLabels support Mar 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant