Skip to content

feat!: update all bundled metrics configs to export Prometheus metrics #151

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

Merged
merged 2 commits into from
Jan 22, 2025

Conversation

obs-gh-mattcotter
Copy link
Collaborator

Description

OB-40055 Update all bundled metrics configs to export Prometheus metrics.

I tested this with a direct write datastream and the metrics look good! I would love some advice on specific things to manually test, as this change won't be caught at all by our automated testing suite.

Checklist

  • Created tests which fail without the change (if possible)
  • Extended the README / documentation, if necessary

@obs-gh-alexlew
Copy link
Collaborator

why is this merging into OB-38651-config-flag instead of just v2?

Base automatically changed from OB-38651-config-flag to v2 January 8, 2025 16:09
@obs-gh-mattcotter
Copy link
Collaborator Author

why is this merging into OB-38651-config-flag instead of just v2?

This was just how I had organized my branches locally, since I assumed the other change would land first. I was doing more extensive testing on this branch and preferred to test with all chagnes. With the other PR landed, I rebased this branch on top of v2.

exporters: [otlphttp/observe]
exporters: [prometheusremotewrite/observe]

metrics/agent-internal-count:
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@obs-gh-alexlew mind taking another look at this part? This is the only change since you last reviewed (directly copy/pasted it to the 3 other packages). This handles converting the count deltas to cumulative metrics.

Copy link
Collaborator

Choose a reason for hiding this comment

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

any reason this has to be a separate pipeline? does this processor do anything to non-delta histogram metrics? also any downsides/footguns to be aware of with this processor?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I double checked the code and it doesn't do anything to cumulative metrics. One possible reason to separate this is that this processor emits internal telemetry data: https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/v0.114.0/processor/deltatocumulativeprocessor/documentation.md but I think going back to a single pipeline makes sense anyway. I'll make that change.

I couldn't find any footguns. I do know that we use it for customer deployments, and also found that it is explicitly recommended in the prometheus docs: https://prometheus.io/docs/guides/opentelemetry/#delta-temporality

@obs-gh-mattcotter obs-gh-mattcotter changed the title feat: update all bundled metrics configs to export Prometheus metrics feat!: update all bundled metrics configs to export Prometheus metrics Jan 10, 2025
@obs-gh-mattcotter obs-gh-mattcotter merged commit 8903b9f into v2 Jan 22, 2025
8 checks passed
@obs-gh-mattcotter obs-gh-mattcotter deleted the OB-40055-prom-metrics branch January 22, 2025 19:06
obs-gh-mattcotter added a commit that referenced this pull request Jan 27, 2025
#151)

### Description

OB-40055 Update all bundled metrics configs to export Prometheus
metrics.
obs-gh-mattcotter added a commit that referenced this pull request Feb 3, 2025
#151)

### Description

OB-40055 Update all bundled metrics configs to export Prometheus
metrics.
obs-gh-mattcotter added a commit that referenced this pull request Feb 5, 2025
#151)

### Description

OB-40055 Update all bundled metrics configs to export Prometheus
metrics.
obs-gh-mattcotter added a commit that referenced this pull request Feb 5, 2025
#151) (#157)

OB-40055 Update all bundled metrics configs to export Prometheus
metrics.
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.

2 participants