Tracer Version(s)
v2.0.0-rc.20
Go Version(s)
go version go1.24.3 linux/amd64
Bug Report
Unix URLs cannot be handled like this:
switch u.Scheme {
case "unix", "http", "https":
c.agentURL = &url.URL{
Scheme: u.Scheme,
Host: u.Host,
}
default:
log.Warn("Unsupported protocol %q in Agent URL %q. Must be one of: http, https, unix.", u.Scheme, agentURL)
}
u.Host is always empty, u.Path contains the path to the socket.
Reproduction Code
traceProvider := ddotel.NewTracerProvider(
tracer.WithAgentURL("unix:///var/run/datadog/apm.socket"),
tracer.WithSamplerRate(0.01),
)
Error Logs
WARN: DIAGNOSTICS Unable to reach agent intake: Post "http://UDS_/v0.4/traces": dial unix: missing address
Go Env Output
No response
Tracer Version(s)
v2.0.0-rc.20
Go Version(s)
go version go1.24.3 linux/amd64
Bug Report
Unix URLs cannot be handled like this:
u.Hostis always empty,u.Pathcontains the path to the socket.Reproduction Code
Error Logs
Go Env Output
No response