Skip to content

Add Karpenter metrics integration to OTEL Container Insights - #322

Closed
vaishnavi-30-beep wants to merge 12 commits into
aws-observability:release-6.2.0from
vaishnavi-30-beep:feature/karpenter-integration
Closed

Add Karpenter metrics integration to OTEL Container Insights#322
vaishnavi-30-beep wants to merge 12 commits into
aws-observability:release-6.2.0from
vaishnavi-30-beep:feature/karpenter-integration

Conversation

@vaishnavi-30-beep

@vaishnavi-30-beep vaishnavi-30-beep commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

This PR adds a Karpenter metrics integration to the OTEL Container Insights pipeline.
When enabled, the cluster-scraper agent automatically discovers and scrapes Karpenter's
Prometheus metrics endpoint, enriches them with Kubernetes semantic conventions, and
exports to CloudWatch via OTLP.

Description of changes:
values.yaml

  • Added otelContainerInsights.integrations.karpenter configuration section with
    enabled, namespace, and port parameters

_otel-container-insights-cluster-scraper-config.tpl

  • Added Prometheus receiver using Kubernetes pod service discovery
  • Added scope processor for pipeline attribution
  • Added groupbyattrs and transform processors for K8s semantic convention enrichment
  • Added dedicated resourcedetection instance (cloud-level attributes only, no host/AZ)
  • Added pipeline definition wiring receiver through processors to exporter

Testing

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

movence and others added 5 commits June 10, 2026 10:57
* Add OTEL Container Insights infrastructure (aws-observability#282)

* Add v6.0.0 release notes

* Cluster-scraper deployment now uses cloudwatch-agent SA (cluster-scraper SA retained as dead resource)

* Bump chart version to 6.0.1 and add release notes

* Scope config-map permission for cloudwatch-agent to namespace only (aws-observability#287)

* scope configmap permission to namesapce

* integ tests

* updates

* Retain configmap get permission at cluster scope (aws-observability#291)

* Fix template whitespace control and hardcoded test names

- Use {{- if instead of {{ if in cloudwatch-agent-role.yaml and
  cloudwatch-agent-rolebinding.yaml to prevent leading blank lines
- Extract agentName constant in configmap_permission_scoping_test.go
  to replace hardcoded strings

* Keep configmaps get at cluster scope, scope create/update to namespace

- Add configmaps get-only rule to ClusterRole
- Narrow namespace-scoped Role to create and update only
- Update test assertions to match

* Run integration tests on PRs targeting release-* branches

* Set hostNetwork: true for default $.agent

* Feature/ksm enrichment and label preservation (aws-observability#296)

* Fix agent.config bleed-through into cluster-scraper deployment (aws-observability#298)

* Fix scrapeTimeout, add missing scrape_timeout, remove dead RBAC, cleanup docs and tests (aws-observability#297)

* Add ClusterIP Service for node-exporter and use service DNS for scraping (aws-observability#304)

* Refactor fluent-bit region-specific (isolated) config using tpl conditionals (aws-observability#271)

* Pin GitHub Actions to commit SHAs (aws-observability#306)

* minor fixes (aws-observability#307)

* release v6.1.0

* Add LIS CSI metrics support to OTEL container insights config (aws-observability#308)

Add prometheus receiver, scope transform, attribute promote transform,
and pipeline for local instance store CSI driver metrics collection,
mirroring the existing EBS CSI pattern. Scrapes pods with label
app=ec2-instance-store-plugin in kube-system namespace and promotes
instance_id and volume_id to resource attributes.

* feat(otel): Add k8sattributes processor node filter to daemonset (aws-observability#311)

* fix(integration-test): include node-exporter-service in EKS resource counts (aws-observability#312)

* Add OTEL-native Container Insights log pipelines (app, host) (aws-observability#310)

* release v6.2.0

* Address PR review: use v0.18 CRD schema, add version bumps to release notes

---------

Co-authored-by: Louise Allen <147041218+louisall@users.noreply.github.com>
Co-authored-by: Kaushik Surya <kausyas@amazon.com>
Co-authored-by: Kaushik Surya <108111936+sky333999@users.noreply.github.com>
Co-authored-by: Petru Anica-Popa <66786772+petruanica@users.noreply.github.com>
Co-authored-by: Trey Richbourg <63218430+treyrichbourg@users.noreply.github.com>
Co-authored-by: POOJA REDDY NATHALA <poojardy@amazon.com>
Co-authored-by: Michael O'Neill <miconeil@amazon.com>
Co-authored-by: Mitali Salvi <mitsalvi@amazon.com>
…bility#318)

* Update featuregate IDs to match operator dependency bump
…tion configuration in supported regions (aws-observability#316)

* Support nodejs autoInstrumentationConfiguration merge and document its service_events/dynamic_instrumentation configs, disable service-events in unsupported regions

* Add integration test for service-events region gating

* update test region

* update documentation for service_events config

* update service-event regions

* update service-events to be disabled in CN/ISO/Gov regions

* update regions and drop cosmetic `nodejs: {}`
Comment thread charts/amazon-cloudwatch-observability/values.yaml Outdated
@miconeilaws

Copy link
Copy Markdown
Collaborator

Diff against release-6.3.0; that should be the next release, release-6.2.0 was the most recent release which has already gone out

@vaishnavi-30-beep
vaishnavi-30-beep force-pushed the feature/karpenter-integration branch from 10cef46 to a4b5d76 Compare July 2, 2026 09:56
movence and others added 6 commits July 2, 2026 11:23
* Add OTEL Container Insights infrastructure (aws-observability#282)

* Add v6.0.0 release notes

* Cluster-scraper deployment now uses cloudwatch-agent SA (cluster-scraper SA retained as dead resource)

* Bump chart version to 6.0.1 and add release notes

* Scope config-map permission for cloudwatch-agent to namespace only (aws-observability#287)

* scope configmap permission to namesapce

* integ tests

* updates

* Retain configmap get permission at cluster scope (aws-observability#291)

* Fix template whitespace control and hardcoded test names

- Use {{- if instead of {{ if in cloudwatch-agent-role.yaml and
  cloudwatch-agent-rolebinding.yaml to prevent leading blank lines
- Extract agentName constant in configmap_permission_scoping_test.go
  to replace hardcoded strings

* Keep configmaps get at cluster scope, scope create/update to namespace

- Add configmaps get-only rule to ClusterRole
- Narrow namespace-scoped Role to create and update only
- Update test assertions to match

* Run integration tests on PRs targeting release-* branches

* Set hostNetwork: true for default $.agent

* Feature/ksm enrichment and label preservation (aws-observability#296)

* Fix agent.config bleed-through into cluster-scraper deployment (aws-observability#298)

* Fix scrapeTimeout, add missing scrape_timeout, remove dead RBAC, cleanup docs and tests (aws-observability#297)

* Add ClusterIP Service for node-exporter and use service DNS for scraping (aws-observability#304)

* Refactor fluent-bit region-specific (isolated) config using tpl conditionals (aws-observability#271)

* Pin GitHub Actions to commit SHAs (aws-observability#306)

* minor fixes (aws-observability#307)

* release v6.1.0

* Add LIS CSI metrics support to OTEL container insights config (aws-observability#308)

Add prometheus receiver, scope transform, attribute promote transform,
and pipeline for local instance store CSI driver metrics collection,
mirroring the existing EBS CSI pattern. Scrapes pods with label
app=ec2-instance-store-plugin in kube-system namespace and promotes
instance_id and volume_id to resource attributes.

* feat(otel): Add k8sattributes processor node filter to daemonset (aws-observability#311)

* fix(integration-test): include node-exporter-service in EKS resource counts (aws-observability#312)

* Add OTEL-native Container Insights log pipelines (app, host) (aws-observability#310)

* release v6.2.0

* Address PR review: use v0.18 CRD schema, add version bumps to release notes

---------

Co-authored-by: Louise Allen <147041218+louisall@users.noreply.github.com>
Co-authored-by: Kaushik Surya <kausyas@amazon.com>
Co-authored-by: Kaushik Surya <108111936+sky333999@users.noreply.github.com>
Co-authored-by: Petru Anica-Popa <66786772+petruanica@users.noreply.github.com>
Co-authored-by: Trey Richbourg <63218430+treyrichbourg@users.noreply.github.com>
Co-authored-by: POOJA REDDY NATHALA <poojardy@amazon.com>
Co-authored-by: Michael O'Neill <miconeil@amazon.com>
Co-authored-by: Mitali Salvi <mitsalvi@amazon.com>
@vaishnavi-30-beep
vaishnavi-30-beep force-pushed the feature/karpenter-integration branch from a4b5d76 to 1e98cfe Compare July 2, 2026 10:32
@vaishnavi-30-beep

Copy link
Copy Markdown
Contributor Author

Closed in favor of [https://github.com//pull/325] — retargeted to release-6.3.0

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.

6 participants