Skip to content

Conversation

@chen-anders
Copy link

Resolves: #1721

This PR resolves the issue around using the opentelemetry-ruby SDK for apps that send traces to an IPv6 endpoint using the suggested fix in the original issue. We also add some tests for verifying the expected value of the collector hostname based on a passed-in value.

Reviewer's Note: Tests were written with significant AI assistance.

@fbogsany fbogsany changed the title Fix issue with sending traces to IPv6 endpoints Fix: issue with sending traces to IPv6 endpoints Oct 23, 2025

def http_connection(uri, ssl_verify_mode, certificate_file, client_certificate_file, client_key_file)
http = Net::HTTP.new(uri.host, uri.port)
http = Net::HTTP.new(uri.hostname, uri.port)
Copy link
Contributor

Choose a reason for hiding this comment

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

Thank you for opening this PR, @chen-anders! I appreciate the Reviewer's note. The tests look good to me, but I think we should add them to the other libraries getting the IPv6 compatible hostname too. Could you update the tests in otlp-http, otlp-logs and otlp-metrics too?

@arielvalentin arielvalentin changed the title Fix: issue with sending traces to IPv6 endpoints fix: issue with sending traces to IPv6 endpoints Oct 24, 2025
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.

opentelemetry-exporter-otlp: http_connection does not handle ipv6 host

3 participants