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

fix: Propagate response attributes on Faraday::Error #912

Merged
merged 1 commit into from
Mar 22, 2024

Conversation

CGA1123
Copy link
Contributor

@CGA1123 CGA1123 commented Mar 22, 2024

The current Faraday middleware won't report http.status_code in
cases where an error is raised via another middleware (such as
:raise_error or :json).

This adds a special case for subclasses of Faraday::Error which have
response information available, so that http.status_code & the span
status are still added to the span.

The current `Faraday` middleware won't report `http.status_code` in
cases where an error is raised via another middleware (such as
`:raise_error` or `:json`).

This adds a special case for subclasses of `Faraday::Error` which have
response information available, so that `http.status_code` the span
status are still added to the span.
Copy link

linux-foundation-easycla bot commented Mar 22, 2024

CLA Signed


The committers listed above are authorized under a signed CLA.

@arielvalentin
Copy link
Collaborator

Thanks for the contribution @CGA1123 !

@arielvalentin arielvalentin self-assigned this Mar 22, 2024
@arielvalentin arielvalentin changed the title feat: Propagate response attributes on Faraday::Error fix: Propagate response attributes on Faraday::Error Mar 22, 2024
@arielvalentin arielvalentin merged commit da831f0 into open-telemetry:main Mar 22, 2024
51 of 52 checks passed
@CGA1123
Copy link
Contributor Author

CGA1123 commented Mar 22, 2024

Thanks for the speeeeeedy turn-around on this @arielvalentin 🙇‍♂️

@CGA1123 CGA1123 deleted the cga1123/faraday-errs branch March 22, 2024 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants