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

change trace exporter trasnport protocol from grpc to http/protobuf #66

Merged
merged 1 commit into from
Jan 30, 2024
Merged

change trace exporter trasnport protocol from grpc to http/protobuf #66

merged 1 commit into from
Jan 30, 2024

Conversation

wangzlei
Copy link
Contributor

Issue #, if available:

Trace otlp exporter in java EKS operator is grpc, does not follow OTel specification recommendation http/protobuf

Description of changes:

Change TraceOtlpExporter protocol from grpc to http/protobuf

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@@ -2,7 +2,8 @@
"OTEL_SMP_ENABLED": "true",
"OTEL_TRACES_SAMPLER_ARG": "endpoint=http://cloudwatch-agent.amazon-cloudwatch:2000",
"OTEL_TRACES_SAMPLER": "xray",
"OTEL_EXPORTER_OTLP_TRACES_ENDPOINT": "http://cloudwatch-agent.amazon-cloudwatch:4315",
"OTEL_EXPORTER_OTLP_PROTOCOL": "http/protobuf",
"OTEL_EXPORTER_OTLP_TRACES_ENDPOINT": "http://cloudwatch-agent.amazon-cloudwatch:4316/v1/traces",

Choose a reason for hiding this comment

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

Q: have we tested this endpoint http://cloudwatch-agent.amazon-cloudwatch:4316/v1/traces with traces in the current CWAgent?

Copy link
Contributor Author

@wangzlei wangzlei Jan 29, 2024

Choose a reason for hiding this comment

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

From OTel doc, http url v1/traces is for tracs, v1/metrics for metrics and v1/logs for logs.
I verified the Agent http traces endpoint in local by settingOTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://localhost:4316/v1/traces, but haven't verified in operator.

OTEL_EXPORTER_OTLP_PROTOCOL=http/protobuf OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://localhost:4316/v1/traces OTEL_METRICS_EXPORTER=none OTEL_SMP_ENABLED=true OTEL_AWS_SMP_EXPORTER_ENDPOINT=http://localhost:4315 java -javaagent:/Users/wangzl/workspace/appsig/aws-otel-java-instrumentation/otelagent/build/libs/aws-opentelemetry-agent-1.32.0-SNAPSHOT.jar -jar ./build/libs/spring-boot-0.0.1-SNAPSHOT.jar Application

Choose a reason for hiding this comment

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

Thanks! I think the local verification should be sufficient.

Copy link

@thpierce thpierce left a comment

Choose a reason for hiding this comment

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

Changes seem reasonable, please describe testing done to show these changes will work as expected.

Copy link

@mxiamxia mxiamxia left a comment

Choose a reason for hiding this comment

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

LGTM!

@sky333999 sky333999 merged commit 0dae080 into aws:main Jan 30, 2024
1 check passed
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.

4 participants