-
Notifications
You must be signed in to change notification settings - Fork 862
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
Break out GrpcSender, GrpcSenderProvider #5617
Conversation
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #5617 +/- ##
=========================================
Coverage 91.25% 91.25%
- Complexity 5016 5032 +16
=========================================
Files 554 556 +2
Lines 14860 14861 +1
Branches 1387 1389 +2
=========================================
+ Hits 13561 13562 +1
- Misses 895 896 +1
+ Partials 404 403 -1
☔ View full report in Codecov by Sentry. |
exporters/common/src/main/java/io/opentelemetry/exporter/internal/RetryUtil.java
Outdated
Show resolved
Hide resolved
I don't love the name
|
I don't mind What about Or |
"grpc-transport" sounds like it could also describe our hand-rolled grpc transport layer
it may be a little subtle for some people, but the whole thing is kinda subtle (similar, not necessarily better) |
If others agree I'll update the artifact name to this^^. |
@jkwatson any thoughts on this? |
I haven't spent a lot of time thinking about this...but my only thought currently is that this adds 3 new published modules, none of which have any public-facing APIs. That feels ... odd to me ... and I haven't really thought through the pros and cons of that. |
It is a bit odd, but the alternative is using gradle exclude syntax to manage transitive dependencies not part of I think this is the cleanest way to handle the sprawl of use cases we want to support as dictated by the java ecosystem. And with the I do think that this is complex enough where we need some documentation. I'm imagining a list of use cases like and corresponding dependency management instruments, like: "If using java 11+ and you prefer to avoid extra dependencies, use the following configuration: ...". I can take an AI to add this kind of documentation to opentelemetry.io to help alleviate confusion. |
Do we want to make these new modules alpha until we've settled on naming? Or are we confident enough that the names are "good enough" to go with? |
I think the names are good enough. Marking the artifacts as alpha indicates that the've taken a step back in stability / reliability, which isn't the case. I will note that the |
Resolves #5572.
This PR touches a lot of files, and I'm not sure it can be reasonably split up. The HttpSender version was able to be split up because there was initially only an okhttp implementation - the jdk implementation was green field. In the GrpcSender case, there are two implementations (okhttp and grpc-upstream) which need to be supported out of the box. On the bright side, the patterns here mirror the HttpSender implementation so there's very little new material.
Some details about the implementation:
opentelemetry-exporter-sender-okhttp
artifact. The GrpcSender implementation doesn't require any new artifacts so better to package it with HttpSender to reduce artifact sprall.opentelemetry-exporter-sender-grpc-upstream
.opentelemetry-exporter-sender-grpc-upstream
opentelemetry-exporter-sender-okhttp
OtlpGrpc{Signal}ExporterBuilder#setChannel(ManagedChannel)
On that last note, its technically redundant to require users to include the grpc upstream artifact AND explicitly set the managed channel. We might consider adjusting the behavior to use grpc upstream if its the only GrpcSenderProvider implementatino present. Doing so would get us back into the business of configuring
ManagedChannel
instances from configuration parameters, which we stopped doing when we deprecated#setChannel(ManagedChannel)
.