improved DruidDataSource error log, add errorCode & sqlState

This commit is contained in:
高铁
2016-02-25 09:42:21 +08:00
parent 3cf7cdf59b
commit e1fa75bae3
@@ -1933,7 +1933,7 @@ public class DruidDataSource extends DruidAbstractDataSource
try {
connection = createPhysicalConnection();
} catch (SQLException e) {
LOG.error("create connection error, url: " + jdbcUrl, e);
LOG.error("create connection error, url: " + jdbcUrl + ", errorCode " + e.getErrorCode() + ", state " + e.getSQLState(), e);
errorCount++;