Skip to content

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

Merged
yschimke merged 3 commits into
square:masterfrom
yschimke:103
Jan 5, 2023
Merged

Expand 103 handling to other non-specific 1XX messages.#7629
yschimke merged 3 commits into
square:masterfrom
yschimke:103

Conversation

@yschimke

@yschimke yschimke commented Jan 4, 2023

Copy link
Copy Markdown
Collaborator

The basic implementation for #2257

Continuation of #7479

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

@yschimke yschimke requested a review from swankjesse January 4, 2023 02:43
@yschimke

yschimke commented Jan 4, 2023

Copy link
Copy Markdown
Collaborator Author

cc @reschke

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

reschke commented Jan 4, 2023

Copy link
Copy Markdown
Contributor

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
Copy Markdown
Contributor

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).

Comment thread okhttp/src/jvmMain/kotlin/okhttp3/internal/http/CallServerInterceptor.kt Outdated
Comment thread okhttp/src/jvmMain/kotlin/okhttp3/internal/http1/Http1ExchangeCodec.kt Outdated

@swankjesse swankjesse left a comment

Copy link
Copy Markdown
Collaborator

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
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