*) Suppressing stackTraces in proxyError message for "connect timed out" errors

See: http://www.yacy-forum.de/viewtopic.php?t=1504
*) Increasing default http client timeout

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@1129 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
theli 20 years ago
parent 4e73035aef
commit 7e670894d9

@ -1084,7 +1084,7 @@ public final class httpd implements serverHandler {
switch (errorcase) {
case 4:
tp.put("errorMessageType_detailedErrorMsg",(detailedErrorMsgText==null)?"":detailedErrorMsgText);
tp.put("errorMessageType_detailedErrorMsg",(detailedErrorMsgText==null)?"":detailedErrorMsgText.replaceAll("\n","<br>"));
break;
case 5:
tp.put("errorMessageType_file",(detailedErrorMsgFile==null)?"":detailedErrorMsgFile);

@ -74,6 +74,7 @@ import java.net.ConnectException;
import java.net.MalformedURLException;
import java.net.NoRouteToHostException;
import java.net.Socket;
import java.net.SocketTimeoutException;
import java.net.URL;
import java.net.UnknownHostException;
import java.util.Date;
@ -1295,7 +1296,9 @@ public final class httpdProxyHandler extends httpdAbstractHandler implements htt
} else if (e instanceof NoRouteToHostException) {
errorMessage = "No route to destination host";
} else if (e instanceof UnknownHostException) {
errorMessage = "IP address of the destination host could not be determined";
errorMessage = "IP address of the destination host could not be determined";
} else if (e instanceof SocketTimeoutException) {
errorMessage = "Unable to establish a connection to the destination host. Connect timed out.";
} else {
String exceptionMsg = e.getMessage();
if ((exceptionMsg != null) && (exceptionMsg.indexOf("Corrupt GZIP trailer") >= 0)) {

@ -19,7 +19,7 @@ port = 8080
# since this applies only to the client-proxy connection,
# it can be rather short
# milliseconds
clientTimeout = 8000
clientTimeout = 30000
# maximal number of httpd sessions
# a client may open several connections at one, and the httpdMaxActiveSessions value sets

Loading…
Cancel
Save