[
https://issues.apache.org/jira/browse/HTTPCLIENT-1337?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13630253#comment-13630253
]
Oleg Kalnichevski commented on HTTPCLIENT-1337:
-----------------------------------------------
Bill
Do I understand this correctly that the main problem is not about not retrying
the request automatically but rather about some unit tests failing with
InterruptedIOException unexpectedly?
To answer your question: I do not think that one aborted request poisoning
subsequent request(s) is likely. Requests never get hold of the real connection
object. What they get is a dynamic proxy that among many things keep track of
whether or not request execution has been explicitly aborted by the user. Each
request gets its own connection proxy and therefore should be fully insulated
from other requests. What is more likely, though, is that unit tests are not
fully isolated and may be leaking state.
Oleg
> Either DefaultHttpRequestRetryHandler:98 should retry on
> InterruptedIOException, or DefaultClientConnection's opening() should throw
> something that can be retried.
> -------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: HTTPCLIENT-1337
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1337
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Components: HttpClient
> Affects Versions: 4.2.2
> Environment: On a linux 2.6 x86 box with 4.2.1 http client library.
> Reporter: Bill Murphy
> Priority: Minor
>
> I have seen a stack like the following:
> Caused by: java.io.InterruptedIOException: Connection already shutdown
> at
> org.apache.http.impl.conn.DefaultClientConnection.opening(DefaultClientConnection.java:121)
>
> at
> org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:169)
>
> at
> org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:151)
> at
> org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:125)
>
> at
> org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:640)
>
> at
> org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:479)
>
> at
> org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906)
>
> at
> waggle.core.http.impl41.XHTTP41Session.executeMethod(XHTTP41Session.java:358)
>
> And I've read Issue #881, but that doesn't seem to contain the fix for my
> problem.
> I don't really understand the line that throws the InterruptedIOException, as
> it seems to me, it should just retry right then. If it cannot retry right
> then, why doesn't the DefaultHttpRequestRetryHandler perform a retry under
> these circumstances?
> I cannot make this exception happen with total reliability, but it breaks one
> of our automated builds test runs about 2 times per week. I'm hoping I've
> included enough information to be of some use, if I can answer any questions
> or provide any more information (or if there's something else I should do on
> my side instead of reporting this as an issue), please advise me via email as
> I might not check back with this issue tracking system.
> Thanks!
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]