Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[protocol/exporter]: should user-agent header be configurable via OTEL_EXPORTER_OTLP_HEADERS? #4230

Open
david-luna opened this issue Sep 26, 2024 · 1 comment
Labels
spec:protocol Related to the specification/protocol directory

Comments

@david-luna
Copy link

We had this question in yesterday's JS SIG (2024-09-25) and originates from the issue I've opened a while ago open-telemetry/opentelemetry-js#4447

From the spec:

Key-value pairs to be used as headers associated with gRPC or HTTP requests.

User-Agent is a header too but in some implementations exporters usually set it up following the recommendation in the spec and it cannot be modified see:

Should we allow to override the header although the user might not follow the spec?

@david-luna david-luna added the spec:protocol Related to the specification/protocol directory label Sep 26, 2024
@dmathieu
Copy link
Member

RFC 7231 states:

The User-Agent field-value consists of one or more product identifiers

In the case of OTLP exporters, the product identifier is OpenTelemetry, not the user's application, despite it happening within the said app.
So even if some folks may want to override it, and maybe we want to support it, the formal recommendation should probably not be to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
spec:protocol Related to the specification/protocol directory
Projects
None yet
Development

No branches or pull requests

2 participants