ignore Closed Connection error, fix #3836

This commit is contained in:
高铁
2020-10-07 01:19:11 +08:00
parent b9d6c01d99
commit 61157c53c8
2 changed files with 25 additions and 2 deletions
@@ -105,7 +105,17 @@ public final class JdbcUtils implements JdbcConstants {
try {
x.close();
} catch (Exception e) {
LOG.debug("close statement error", e);
boolean printError = true;
if (e instanceof java.sql.SQLRecoverableException
&& "Closed Connection".equals(e.getMessage())
) {
printError = false;
}
if (printError) {
LOG.debug("close statement error", e);
}
}
}