From 89c9faa89e51caf73a1fd7de41acd8e34e0fe08f Mon Sep 17 00:00:00 2001 From: theli Date: Wed, 10 Aug 2005 06:15:47 +0000 Subject: [PATCH] *) More graceful logging output in crawler See: http://www.yacy-forum.de/viewtopic.php?t=894 git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@511 6c8d7289-2bf4-0310-a012-ef5d649a1542 --- source/de/anomic/plasma/plasmaCrawlWorker.java | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/source/de/anomic/plasma/plasmaCrawlWorker.java b/source/de/anomic/plasma/plasmaCrawlWorker.java index 3b66e38dd..e7d9a9c04 100644 --- a/source/de/anomic/plasma/plasmaCrawlWorker.java +++ b/source/de/anomic/plasma/plasmaCrawlWorker.java @@ -403,20 +403,25 @@ public final class plasmaCrawlWorker extends Thread { String errorMsg = e.getMessage(); if (errorMsg != null) { if (e instanceof java.net.BindException) { - log.logWarning("BindException detected while trying to download content from '" + url.toString() + + log.logWarning("CRAWLER BindException detected while trying to download content from '" + url.toString() + "'. Retrying request."); retryCrawling = true; } else if (errorMsg.indexOf("Corrupt GZIP trailer") >= 0) { - log.logWarning("Problems detected while receiving gzip encoded content from '" + url.toString() + + log.logWarning("CRAWLER Problems detected while receiving gzip encoded content from '" + url.toString() + "'. Retrying request without using gzip content encoding."); retryCrawling = true; } else if (errorMsg.indexOf("Socket time-out: Read timed out") >= 0) { - log.logWarning("Read timeout while receiving content from '" + url.toString() + + log.logWarning("CRAWLER Read timeout while receiving content from '" + url.toString() + "'. Retrying request."); retryCrawling = true; + } else if (errorMsg.indexOf("Connection timed out") >= 0) { + log.logWarning("CRAWLER Connection timeout while receiving content from '" + url.toString() + + "'. Retrying request."); + retryCrawling = true; } else if (errorMsg.indexOf("Connection refused") >= 0) { - log.logError("CRAWLER LOADER ERROR2 with URL=" + url.toString() + ": Connection refused"); + log.logError("CRAWLER LOADER ERROR2 with URL=" + url.toString() + ": Connection refused"); } + if (retryCrawling) { load(url,