more explaining error message in case of IOExceptions during html parsing

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@5864 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
orbiter 16 years ago
parent fe51f4d668
commit 1bcc1450cb

@ -671,6 +671,13 @@ public final class plasmaParser {
final String errorMsg = "unsupported charset encoding: " + e.getMessage();
theLogger.logSevere("Unable to parse '" + location + "'. " + errorMsg, e);
throw new ParserException(errorMsg,location, errorMsg);
} catch (final IOException e) {
// IOExceptions may occur during html parsing when a server closes the connection during reading.
// This may happen here, because the html parser is a streaming parser
// that produces surrogates while the connection is active
final String errorMsg = "IOException - server may have closed the connection. " + e.getMessage();
theLogger.logWarning("Unable to parse '" + location + "'. " + errorMsg);
throw new ParserException(errorMsg, location, errorMsg);
} catch (final Exception e) {
// Interrupted- and Parser-Exceptions should pass through
if (e instanceof InterruptedException) throw (InterruptedException) e;

Loading…
Cancel
Save