Merge pull request #1171 from wenshao/master

discard mysql streaming resultSet close error connection
This commit is contained in:
wenshao
2016-04-20 15:01:08 +08:00
2 changed files with 12 additions and 1 deletions
@@ -46,7 +46,7 @@ public class FilterManager {
aliasMap.put(name, (String) entry.getValue());
}
}
} catch (Exception e) {
} catch (Throwable e) {
LOG.error("load filter config error", e);
}
}
@@ -77,6 +77,17 @@ public class MySqlExceptionSorter implements ExceptionSorter {
return true;
}
}
StackTraceElement[] stackTrace = e.getStackTrace();
for (int i = 0; i < stackTrace.length; ++i) {
StackTraceElement element = stackTrace[i];
if ("com.mysql.jdbc.RowDataDynamic".equals(element.getClassName()) //
&& "close".equals(element.getMethodName())
) {
return true;
}
}
return false;
}