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

Traces host info metric #1689

Merged
merged 6 commits into from
Feb 24, 2025
Merged

Traces host info metric #1689

merged 6 commits into from
Feb 24, 2025

Conversation

grcevski
Copy link
Contributor

Adds the traces host info metric export in Beyla for OTEL and Prometheus export to support host based pricing, for vendors that charge with that model.

@grcevski grcevski requested a review from a team as a code owner February 21, 2025 15:02
@@ -536,6 +544,21 @@ func (mr *MetricsReporter) setupSpanMeters(m *Metrics, meter instrument.Meter) e
return nil
}

func (mr *MetricsReporter) setupHostInfoMeter(meter instrument.Meter) error {
if !mr.cfg.SpanMetricsEnabled() || !mr.cfg.ServiceGraphMetricsEnabled() {
Copy link
Contributor

Choose a reason for hiding this comment

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

This check is duplicate before invoking setupHostInfoMeter, but also is inconsistent. Shouldn't be:

if !mr.cfg.SpanMetricsEnabled() && !mr.cfg.ServiceGraphMetricsEnabled() {

?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, you are right, I'll remove it.

Copy link

codecov bot commented Feb 21, 2025

Codecov Report

Attention: Patch coverage is 86.66667% with 6 lines in your changes missing coverage. Please review.

Project coverage is 69.86%. Comparing base (03596e8) to head (ad2e9d8).
Report is 5 commits behind head on main.

Files with missing lines Patch % Lines
pkg/export/otel/metrics.go 81.81% 4 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1689      +/-   ##
==========================================
+ Coverage   69.69%   69.86%   +0.16%     
==========================================
  Files         209      209              
  Lines       20975    21047      +72     
==========================================
+ Hits        14619    14704      +85     
+ Misses       5654     5637      -17     
- Partials      702      706       +4     
Flag Coverage Δ
integration-test 54.31% <86.66%> (+0.46%) ⬆️
k8s-integration-test 54.47% <86.66%> (+0.14%) ⬆️
oats-test 35.13% <24.44%> (-0.12%) ⬇️
unittests 46.18% <24.44%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@mariomac mariomac left a comment

Choose a reason for hiding this comment

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

🚀

@grcevski grcevski merged commit dc1e1c4 into grafana:main Feb 24, 2025
13 checks passed
@grcevski grcevski deleted the traces_host_info branch February 24, 2025 14:37
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