Skip to content

Fallback to content type in error handler#13413

Closed
delta003 wants to merge 2 commits into
open-telemetry:mainfrom
spiraldb:main
Closed

Fallback to content type in error handler#13413
delta003 wants to merge 2 commits into
open-telemetry:mainfrom
spiraldb:main

Conversation

@delta003
Copy link
Copy Markdown
Contributor

Description

When the request lacks Content-Type, for whatever reason, the response is 500 {"code": 13, "message": "failed to marshal error message"}. In general, this shouldn't happen, but anything hitting a collector server wrongly results in 500 on a collector, which seems wrong (it's a client error).

This is simple to repro:
curl -X GET localhost:4318 with any auth extension returns 500. This is because auth extension returns an error that should propagate as 401, but because of error handling results in 500.

Link to tracking issue

Testing

Documentation

@delta003 delta003 requested a review from a team as a code owner July 17, 2025 14:41
@delta003 delta003 requested a review from TylerHelmuth July 17, 2025 14:41
@linux-foundation-easycla
Copy link
Copy Markdown

linux-foundation-easycla Bot commented Jul 17, 2025

CLA Signed

The committers listed above are authorized under a signed CLA.

* Fallback to content type in error handler

* This commit will be squashed.
@delta003
Copy link
Copy Markdown
Contributor Author

#13414

@delta003 delta003 closed this Jul 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant