[
https://issues.apache.org/jira/browse/HTTPCLIENT-1337?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13628806#comment-13628806
]
Oleg Kalnichevski commented on HTTPCLIENT-1337:
-----------------------------------------------
Bill
I respectfully disagree. DefaultClientConnection#opening throws
InterruptedIOException if the request has been explicitly aborted by the user.
I do not think the request should be automatically retried. What I can do
though is to make it throw a subclass of InterruptedIOException that can be
retried using a custom retry handler.
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]