added the fix to workaround openjdk bug which thrown internal error (ref #629)

This commit is contained in:
galimru 2020-01-27 21:15:04 +04:00
parent 00f68950aa
commit 55e27c1167

View File

@ -274,6 +274,14 @@ public class DefaultBotSession implements BotSession {
} catch (InterruptedException e) {
log.info(e.getLocalizedMessage(), e);
interrupt();
} catch (InternalError e) {
// handle InternalError to workaround OpenJDK bug (resolved since 13.0)
// https://bugs.openjdk.java.net/browse/JDK-8173620
Throwable cause = e.getCause();
if (cause instanceof IOException) {
log.error(e.getLocalizedMessage(), e);
}
throw e;
}
return Collections.emptyList();
}