Zipkin exporter receiving 400 from Open Telemetry Collector
Description of the bug
When sending a trace to an otel-collector, the client receives a 400:
json: cannot unmarshal string into Go struct field Endpoint.remoteEndpoint.Port of type uint16
A repro of this issue can be found here: https://github.com/lukegil/repro-ot-issue
This occurs when a basic "get" is traced, as well as in-the-field cases like when automatically tracing calls to Amazon Cognito.
It appears that the zipkin exporter is explicitly setting port as a string (here, though I could be wrong). Zipkin defines remoteEndpoint.port as being an int.
Share details about your runtime
Operating system details: MacOS 14.1.2 (but also seen on Amz linux) RUBY_ENGINE: "ruby" RUBY_VERSION: "3.0.6" RUBY_DESCRIPTION: "ruby 3.0.6p216 (2023-03-30 revision 23a532679b) [x86_64-darwin22]"
Share a simplified reproduction if possible https://github.com/lukegil/repro-ot-issue
Thanks for all your work! Let me know if I can help
The port seems expecting int, but zipkin is giving string by looking at the remoteEndpoint from your github repo.
Could you try to change this line to_s to to_i see if can fix
👋 This issue has been marked as stale because it has been open with no activity. You can: comment on the issue or remove the stale label to hold stale off for a while, add the keep label to hold stale off permanently, or do nothing. If you do nothing this issue will be closed eventually by the stale bot.
Hi @lukegil, did you get a chance to test @xuan-cao-swi's recommendation?
👋 This issue has been marked as stale because it has been open with no activity. You can: comment on the issue or remove the stale label to hold stale off for a while, add the keep label to hold stale off permanently, or do nothing. If you do nothing this issue will be closed eventually by the stale bot.