-
Notifications
You must be signed in to change notification settings - Fork 1k
Change Spring starter default otlp protocol from gRPC to http/protobuf #10212
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
Change Spring starter default otlp protocol from gRPC to http/protobuf #10212
Conversation
|
cc @zeitlinger |
zeitlinger
left a comment
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.
LGTM - just small nitpick 😄
...a/io/opentelemetry/instrumentation/spring/autoconfigure/exporters/otlp/OtlpExporterUtil.java
Show resolved
Hide resolved
| boolean isHttpProtobuf = Objects.equals(protocol, OtlpConfigUtil.PROTOCOL_HTTP_PROTOBUF); | ||
| boolean isHttpProtobuf = !"grpc".equals(protocol); | ||
|
|
||
| if (protocol != null |
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.
sdk chooses to fail when invalid protocol is specified, see https://github.com/open-telemetry/opentelemetry-java/blob/d9f9812d4375a4229caff43bd681c50b7a45776a/exporters/otlp/all/src/main/java/io/opentelemetry/exporter/otlp/internal/OtlpLogRecordExporterProvider.java#L75
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.
Perhaps it could be rediscussed later with the perspective of what to do with the OTel starter configurations.
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.
I have created #10213
| && !OtlpConfigUtil.PROTOCOL_HTTP_PROTOBUF.equals(protocol)) { | ||
| logger.warn( | ||
| protocol | ||
| + " protocol is not managed. " |
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.
I'd rephrase this to something like Unknown OTLP protocol '{}', using 'http/protobuf' instead.
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.
Done
trask
left a comment
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.
thx!
Fix #10206