mirror of
https://github.com/alibaba/open-code-review.git
synced 2026-07-09 17:28:58 +00:00
* fix(telemetry): support http:// scheme in otlp_endpoint for insecure gRPC Parse the otlp_endpoint scheme before creating the OTLP gRPC exporters: - http://host:port -> strip scheme, call WithInsecure() (plaintext gRPC) - https://host:port -> strip scheme, keep default TLS - host:port -> unchanged, keep default TLS (backward compatible) Scheme matching is case-insensitive. Applies to both the trace and metric exporters in initOTLPProviders. Fixes #268 * fix(telemetry): trim trailing slash from otlp_endpoint after scheme strip Addresses review feedback: a URL-style endpoint with a trailing slash (e.g. "http://localhost:4317/") left the trailing "/" in the address passed to WithEndpoint(), which expects a bare host:port with no path and could cause connection failures. |
||
|---|---|---|
| .. | ||
| config.go | ||
| config_test.go | ||
| events.go | ||
| events_test.go | ||
| exporter.go | ||
| exporter_test.go | ||
| metrics.go | ||
| metrics_test.go | ||
| provider.go | ||
| provider_test.go | ||
| shutdown.go | ||
| shutdown_test.go | ||
| span.go | ||
| span_test.go | ||