Connection timeouts in JEP 321 (HTTP Client)
Simone Bordet
simone.bordet at gmail.com
Wed Aug 1 15:11:07 UTC 2018
Hi,
On Wed, Aug 1, 2018 at 5:01 PM Michael McMahon
<michael.x.mcmahon at oracle.com> wrote:
> I can understand that a server might respond early with an error code
> like 500 before the client has finished sending a very large request body,
> but I don't see how a server would likely respond early with 200.
> Surely, the server has to wait for the whole request body to be received
> successfully, before sending a 200?
Nope.
Not one HTTP RFC forbids to reply with an early 200.
That may actually be a common case for large uploads paired with
polling the server for the request status.
And you would be surprised at how many bad server exist out there, and
how creative people can be in using HTTP.
I would not base the behavior of the JDK HttpClient on false
assumptions, especialy that HTTP responses must finish _after_ HTTP
requests.
It has never been the case since the inception of HTTP.
Thanks!
--
Simone Bordet
---
Finally, no matter how good the architecture and design are,
to deliver bug-free software with optimal performance and reliability,
the implementation technique must be flawless. Victoria Livschitz
More information about the net-dev
mailing list