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

feat(otelx): add support for the GRPC protocol in Otel #784

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

alecsammon
Copy link

@alecsammon alecsammon commented May 13, 2024

Our system cannot currently accept Otel data via http. As such we need support to send this using the GRPC transport option.

This PR adds a new property to allow this to be specified - with the current http as the default option to prevent any breaking changes.

Related Issue or Design Document

Checklist

  • I have read the contributing guidelines and signed the CLA.
  • I have referenced an issue containing the design document if my change introduces a new feature.
  • I have read the security policy.
  • I confirm that this pull request does not address a security vulnerability.
    If this pull request addresses a security vulnerability,
    I confirm that I got approval (please contact [email protected]) from the maintainers to push the changes.
  • I have added tests that prove my fix is effective or that my feature works.
  • I have added the necessary documentation within the code base (if appropriate).

Further comments

@CLAassistant
Copy link

CLAassistant commented May 13, 2024

CLA assistant check
All committers have signed the CLA.

@alecsammon alecsammon changed the title Add support for the GRPC protocol in Otel feat(otel): Add support for the GRPC protocol in Otel May 14, 2024
@alecsammon alecsammon changed the title feat(otel): Add support for the GRPC protocol in Otel feat(otelx): Add support for the GRPC protocol in Otel May 14, 2024
@alecsammon alecsammon changed the title feat(otelx): Add support for the GRPC protocol in Otel feat(otelx): add support for the GRPC protocol in Otel May 14, 2024
@@ -85,22 +85,23 @@ require (
go.opentelemetry.io/contrib/propagators/b3 v1.21.0
go.opentelemetry.io/contrib/propagators/jaeger v1.21.1
go.opentelemetry.io/contrib/samplers/jaegerremote v0.15.1
go.opentelemetry.io/otel v1.21.0
go.opentelemetry.io/otel v1.26.0
Copy link
Author

Choose a reason for hiding this comment

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

required update to support GRPC.
This brought in the other dependency updates.

var client otlptrace.Client
if c.Providers.OTLP.Transport == "GRPC" {
client = getOTLPGRPClient(c)
} else {
Copy link
Author

Choose a reason for hiding this comment

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

It may be required to add http/json and http/protobuf in the future. At the moment we default to the current behaviour
https://opentelemetry.io/docs/specs/otel/protocol/exporter/#specify-protocol

@alecsammon alecsammon marked this pull request as ready for review May 20, 2024 11:14
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