Skip to content

DOC(exporter-otlp-proto-http): clarify endpoint= kwarg requires full signal path - #5633

Open
karlhillx wants to merge 2 commits into
open-telemetry:mainfrom
karlhillx:doc/clarify-otlp-http-endpoint-kwarg
Open

DOC(exporter-otlp-proto-http): clarify endpoint= kwarg requires full signal path#5633
karlhillx wants to merge 2 commits into
open-telemetry:mainfrom
karlhillx:doc/clarify-otlp-http-endpoint-kwarg

Conversation

@karlhillx

Copy link
Copy Markdown

Closes #5628.

The endpoint= kwarg is used verbatim, but the env-var path appends
the signal path in _resolve_endpoint. The previous docstring
("Target URL to which the exporter is going to send ...") didn't
distinguish the two, so users passing a base URL got a permanent 404
at the collector with no hint why.

State the full signal path requirement on the kwarg and point at
OTEL_EXPORTER_OTLP_ENDPOINT for the base-URL case. Behavior unchanged.

Scope: the three HTTP exporters (trace, metric, log). The gRPC
exporters route by service, not path, so they were left alone.

… path

The endpoint= kwarg is used verbatim, while OTEL_EXPORTER_OTLP_ENDPOINT
gets the signal path appended in _resolve_endpoint. The existing
docstring ('Target URL to which the exporter is going to send ...')
doesn't say which of the two the kwarg carries, so users who pass a
base URL with a settings layer or secrets manager get a permanent 404
at the collector with no hint why.

Document that endpoint= must include the full signal path, and that
OTEL_EXPORTER_OTLP_ENDPOINT is the right knob for a base URL.

Closes open-telemetry#5628.
@karlhillx
karlhillx requested a review from a team as a code owner September 6, 2026 01:56
Copilot AI lite review requested due to automatic review settings September 6, 2026 01:56
@linux-foundation-easycla

linux-foundation-easycla Bot commented Sep 6, 2026

Copy link
Copy Markdown

CLA Signed
The committers listed above are authorized under a signed CLA.

  • ✅ login: karlhillx / name: Karl Hill (0298db1)

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

The changes are limited to accurate docstring clarifications consistent with the described behavior and scope (HTTP exporters only).

Pull request overview

This PR clarifies the OTLP/HTTP exporters’ endpoint= constructor argument semantics: when passed explicitly it must be the full signal-specific URL (including /v1/{signal}), while the base-URL behavior is provided via OTEL_EXPORTER_OTLP_ENDPOINT. This addresses the user confusion described in #5628 without changing runtime behavior.

Changes:

  • Updated endpoint parameter docstring for the OTLP/HTTP trace exporter to require the full signal path and to reference OTEL_EXPORTER_OTLP_ENDPOINT for base-URL configuration.
  • Applied the same clarification to the OTLP/HTTP metrics exporter docstring.
  • Applied the same clarification to the OTLP/HTTP logs exporter docstring.
File summaries
File Description
exporter/opentelemetry-exporter-otlp-proto-http/src/opentelemetry/exporter/otlp/proto/http/trace_exporter/init.py Clarifies endpoint= must include /v1/traces; points base-URL users to OTEL_EXPORTER_OTLP_ENDPOINT.
exporter/opentelemetry-exporter-otlp-proto-http/src/opentelemetry/exporter/otlp/proto/http/metric_exporter/init.py Clarifies endpoint= must include /v1/metrics; points base-URL users to OTEL_EXPORTER_OTLP_ENDPOINT.
exporter/opentelemetry-exporter-otlp-proto-http/src/opentelemetry/exporter/otlp/proto/http/_log_exporter/init.py Clarifies endpoint= must include /v1/logs; points base-URL users to OTEL_EXPORTER_OTLP_ENDPOINT.
Review details
  • Files reviewed: 3/3 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@opentelemetry-pr-dashboard

Copy link
Copy Markdown

Pull request dashboard status

Waiting on reviewers · refreshed 2026-09-06 02:25 UTC

Review the latest changes.

Status above doesn't look right?
  • Just replied or pushed? Anything around or after the refresh time above may not be picked up yet — give it a few minutes.
  • Anything look wrong? Report it with what you expected; it helps us improve the dashboard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

OTLP/HTTP exporter: endpoint= kwarg is used verbatim while OTEL_EXPORTER_OTLP_ENDPOINT gets /v1/traces appended, with no docstring saying so

2 participants