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

Expand 103 handling to other non-specific 1XX messages. #7629

Merged
merged 3 commits into from
Jan 5, 2023

Conversation

yschimke
Copy link
Collaborator

@yschimke yschimke commented Jan 4, 2023

The basic implementation for #2257

Continuation of #7479

It doesn't have special handling of 102, such as resetting any timeouts.

@yschimke
Copy link
Collaborator Author

yschimke commented Jan 4, 2023

cc @reschke

@yschimke yschimke marked this pull request as ready for review January 4, 2023 02:46
@reschke
Copy link

reschke commented Jan 4, 2023

It doesn't have special handling of 102, such as resetting any timeouts.

102 doesn't specify any specific changes to timeout handling.


// Early Hints (103) but not supported yet in OkHttp
code == 103 -> true
// Processing & Early Hints (103) but not supported yet in OkHttp
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment is slightly misleading IMHO. Supporting 1xx codes means doing the same thing for all of them, except, well, for the exceptions (being 100 and 101).

It just means consuming the response, until final response is received (and potentially making the information about it available to the caller).

Copy link
Member

@swankjesse swankjesse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is super overdue! Thanks.

@yschimke yschimke merged commit 7e4576c into square:master Jan 5, 2023
yschimke added a commit to yschimke/okhttp that referenced this pull request Jan 5, 2023
swankjesse pushed a commit that referenced this pull request Jan 12, 2023
* Ignore early hints for 4.9.x (#7444)

(cherry picked from commit b565eec)

* Expand 103 handling to other non-specific 1XX messages. (#7629)

(cherry picked from commit 7e4576c)

* Cleanup

* Add a test of 103 handling

* Add copyright

* Add copyright

* Fix cache test for 102/103 (#7633)

(cherry picked from commit 930f138)

* Disable test
@yschimke yschimke deleted the 103 branch May 27, 2023 11:26
This pull request was closed.
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.

3 participants