Martin Zdila wrote:
1. First POST request without body. Fine. Connection is keep-alive.
2. Second POST request with body. Fine, but the connection breaks
prematurely (don't know why).

This may be another bug.

Maybe. To be investigated. A packet log (Wireshark or tcpdump) might be useful.


3. Client detects the faulty connection and retries.
4. Client sends headers, but can't send the body because the stream has
already been exhausted.
5. Server looses patience waiting for the missing entity body and throws
HTTP 400.

When the client retries the entity body stream has already been consumed.
An InputStream can not be reconstructed after is has been read (we don't
buffer). There is no way the request can be retried.

Actually the client should know that and not retry in this case. Oleg, this
looks like a bug to me.

IMHO the InputStream could only be consumed if it is possible to write to the socket.

Martin, you can clearly see from the logs that the stream has been consumed and the body has been written out to the server in the first attempt. Naturally the stream can no longer be consumed in the second attempt.

Cheers

Ortwin

--
[web]  http://www.odi.ch/
[blog] http://www.odi.ch/weblog/
[pgp]  key 0x81CF3416
       finger print F2B1 B21F F056 D53E 5D79 A5AF 02BE 70F5 81CF 3416

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to