Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Abstract prometheus metrics to interfaces #7357

Merged

Conversation

jonathan-innis
Copy link
Contributor

Fixes #N/A

Description

This leverages awslabs/operatorpkg#92 to create abstract metrics so that you can create an arbitrary pipeline for routing metrics beyond prometheus

For instance,

status.TerminationDuration = pmetrics.NewMultiObservation(
	status.TerminationDuration,
	pmetrics.NewEMFObservation(writer, "operatorpkg", "operator_termination_duration_seconds", []string{"group", "kind", "namespace"}),
)

How was this change tested?

make presubmit
/karpenter snapshot

Does this change impact docs?

  • Yes, PR includes docs updates
  • Yes, issue opened: #
  • No

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Copy link

netlify bot commented Nov 8, 2024

Deploy Preview for karpenter-docs-prod canceled.

Name Link
🔨 Latest commit 277327c
🔍 Latest deploy log https://app.netlify.com/sites/karpenter-docs-prod/deploys/672e8c2c259409000895d00c

Copy link
Contributor Author

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/karpenter snapshot

Copy link
Contributor

github-actions bot commented Nov 8, 2024

Snapshot successfully published to oci://021119463062.dkr.ecr.us-east-1.amazonaws.com/karpenter/snapshot/karpenter:0-277327c64b9b2ff1947306bacdcf0d3802e395a5.
To install you must login to the ECR repo with an AWS account:

aws ecr get-login-password --region us-east-1 | docker login --username AWS --password-stdin 021119463062.dkr.ecr.us-east-1.amazonaws.com

helm upgrade --install karpenter oci://021119463062.dkr.ecr.us-east-1.amazonaws.com/karpenter/snapshot/karpenter --version "0-277327c64b9b2ff1947306bacdcf0d3802e395a5" --namespace "kube-system" --create-namespace \
  --set "settings.clusterName=${CLUSTER_NAME}" \
  --set "settings.interruptionQueue=${CLUSTER_NAME}" \
  --set controller.resources.requests.cpu=1 \
  --set controller.resources.requests.memory=1Gi \
  --set controller.resources.limits.cpu=1 \
  --set controller.resources.limits.memory=1Gi \
  --wait

@coveralls
Copy link

Pull Request Test Coverage Report for Build 11750275361

Details

  • 15 of 15 (100.0%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.02%) to 82.798%

Totals Coverage Status
Change from base Build 11748181920: -0.02%
Covered Lines: 5675
Relevant Lines: 6854

💛 - Coveralls

@jonathan-innis jonathan-innis enabled auto-merge (squash) November 8, 2024 23:09
Copy link
Contributor

@rschalo rschalo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jonathan-innis jonathan-innis merged commit 6ffb599 into aws:main Nov 8, 2024
22 of 32 checks passed
@jonathan-innis jonathan-innis deleted the abstract-prometheus-metrics branch November 8, 2024 23:15
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.

3 participants