-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Add support for OTLP export for internal metrics #8097
Conversation
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #8097 +/- ##
==========================================
+ Coverage 90.18% 90.24% +0.05%
==========================================
Files 301 301
Lines 15377 15449 +72
==========================================
+ Hits 13868 13942 +74
+ Misses 1222 1221 -1
+ Partials 287 286 -1
☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hype!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🥳
opts := []otlpmetricgrpc.Option{} | ||
|
||
if len(otlpConfig.Endpoint) > 0 { | ||
opts = append(opts, otlpmetricgrpc.WithEndpoint(otlpConfig.Endpoint)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be a required option?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By default, if an environment variable is not set, and this option is not passed, "localhost:4317" will be used.
It is not required: https://pkg.go.dev/go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc#WithEndpoint
252cbfa
to
127e1a2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few comments on the config. Since they were not added by this PR we may consider them separately if this is not the first use of those fields
54687d1
to
a41c0d2
Compare
Signed-off-by: Alex Boten <aboten@lightstep.com>
Signed-off-by: Alex Boten <aboten@lightstep.com>
a41c0d2
to
b1d0f13
Compare
Internal collector metrics can now be exported via OTLP
using the otel-go otlpgrpc and otlphttp exporters.
Closes #7641
Follow up to #8113