You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by ol...@apache.org on 2008/10/30 14:56:25 UTC
svn commit: r709159 - in /httpcomponents/httpclient/trunk: RELEASE_NOTES.txt
module-client/src/main/java/org/apache/http/impl/client/DefaultHttpRequestRetryHandler.java
Author: olegk
Date: Thu Oct 30 06:56:25 2008
New Revision: 709159
URL: http://svn.apache.org/viewvc?rev=709159&view=rev
Log:
HTTPCLIENT-806: DefaultHttpMethodRetryHandler will no longer retry on ConnectExceptions
Modified:
httpcomponents/httpclient/trunk/RELEASE_NOTES.txt
httpcomponents/httpclient/trunk/module-client/src/main/java/org/apache/http/impl/client/DefaultHttpRequestRetryHandler.java
Modified: httpcomponents/httpclient/trunk/RELEASE_NOTES.txt
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/RELEASE_NOTES.txt?rev=709159&r1=709158&r2=709159&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/RELEASE_NOTES.txt (original)
+++ httpcomponents/httpclient/trunk/RELEASE_NOTES.txt Thu Oct 30 06:56:25 2008
@@ -1,6 +1,10 @@
Changes since 4.0 beta 1
-------------------
+* [HTTPCLIENT-806] DefaultHttpMethodRetryHandler will no longer retry
+ on ConnectExceptions.
+ Contributed by Oleg Kalnichevski <olegk at apache.org>
+
* DigestScheme can use an arbitrary digest algorithm requested by the
target server (such SHA) as long as this algorithm is supported by
the Java runtime.
Modified: httpcomponents/httpclient/trunk/module-client/src/main/java/org/apache/http/impl/client/DefaultHttpRequestRetryHandler.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/module-client/src/main/java/org/apache/http/impl/client/DefaultHttpRequestRetryHandler.java?rev=709159&r1=709158&r2=709159&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/module-client/src/main/java/org/apache/http/impl/client/DefaultHttpRequestRetryHandler.java (original)
+++ httpcomponents/httpclient/trunk/module-client/src/main/java/org/apache/http/impl/client/DefaultHttpRequestRetryHandler.java Thu Oct 30 06:56:25 2008
@@ -33,6 +33,7 @@
import java.io.IOException;
import java.io.InterruptedIOException;
+import java.net.ConnectException;
import java.net.UnknownHostException;
import javax.net.ssl.SSLHandshakeException;
@@ -101,6 +102,10 @@
// Unknown host
return false;
}
+ if (exception instanceof ConnectException) {
+ // Connection refused
+ return false;
+ }
if (exception instanceof SSLHandshakeException) {
// SSL handshake exception
return false;