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

Wrong content-type in CollectorTraceExporter header #2500

Closed
MartinNovak1991 opened this issue Sep 27, 2021 · 3 comments
Closed

Wrong content-type in CollectorTraceExporter header #2500

MartinNovak1991 opened this issue Sep 27, 2021 · 3 comments
Labels
bug Something isn't working stale

Comments

@MartinNovak1991
Copy link

MartinNovak1991 commented Sep 27, 2021

What version of OpenTelemetry are you using?

"@opentelemetry/api": "^1.0.0",
"@opentelemetry/context-zone": "^0.24.0",
"@opentelemetry/exporter-collector": "^0.24.0",
"@opentelemetry/instrumentation": "^0.24.0",
"@opentelemetry/instrumentation-document-load": "^0.24.0",
"@opentelemetry/instrumentation-fetch": "^0.24.0",
"@opentelemetry/instrumentation-user-interaction": "^0.24.0",
"@opentelemetry/instrumentation-xml-http-request": "^0.24.0",
"@opentelemetry/metrics": "^0.24.0",
"@opentelemetry/propagator-b3": "^0.24.0",
"@opentelemetry/tracing": "^0.24.0",
"@opentelemetry/web": "^0.24.0",

BACKEND: opentelemetry-collector-contrib v0.34.0

What did you do?

We use opentelemetry-collector-contrib on backend. It was working before update (old version 0.28.0) well. But after update -> 0.34.0 -> this collector answers with http-code "404 Not Found". I found out the problem is in content-type. If I request collectors endpoint with content-type: application/json I get "400 Bad Request", what is ok because my request body is empty.
opentelemetry-js sends content-type: plain/text only.

I request default http receiver on this collector.

What did you expect to see?

http-code 200 OK

What did you see instead?

http-code 404 Not Found
MicrosoftTeams-image (2)

MicrosoftTeams-image (3)

Additional context

Is it possible to add content-type setter for:
new SimpleSpanProcessor(new CollectorTraceExporter(COLLECTOR_OPTIONS));

or to fix content-type in opentelemetry-js ?

@MartinNovak1991 MartinNovak1991 added the bug Something isn't working label Sep 27, 2021
@vmarchaud
Copy link
Member

This has been fixed with #2336 and released in 0.25.0

@github-actions
Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.

@github-actions github-actions bot added the stale label Nov 29, 2021
@github-actions
Copy link

This issue was closed because it has been stale for 14 days with no activity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working stale
Projects
None yet
Development

No branches or pull requests

2 participants