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

http: Unwrap nested exceptions to handle retryable transport errors #2634

Closed
wants to merge 1 commit into from

Conversation

kreuzerkrieg
Copy link
Contributor

@kreuzerkrieg kreuzerkrieg commented Feb 4, 2025

Enhance the HTTP client's exception handling by unwrapping nested exceptions. This allows the client to detect retryable transport errors even when they're encapsulated within multiple layers of exceptions. By identifying these underlying transport errors, the client can implement appropriate retry logic, improving reliability during transient network issues.
Also add GNUTLS_E_PREMATURE_TERMINATION error to the list of retryable error since technically it is a transport issue

@kreuzerkrieg kreuzerkrieg self-assigned this Feb 4, 2025
@kreuzerkrieg kreuzerkrieg marked this pull request as ready for review February 5, 2025 08:02
@kreuzerkrieg kreuzerkrieg requested a review from xemul February 5, 2025 08:02
Enhance the HTTP client's exception handling by unwrapping nested exceptions. This allows the client to detect retryable transport errors even when they're encapsulated within multiple layers of exceptions. By identifying these underlying transport errors, the client can implement appropriate retry logic, improving reliability during transient network issues. Also add TLS error which is clearly retryable.
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