mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
improve datasource log
This commit is contained in:
@@ -626,7 +626,7 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
poolingPeakTime = System.currentTimeMillis();
|
||||
}
|
||||
} catch (SQLException ex) {
|
||||
LOG.error("init datasource error", ex);
|
||||
LOG.error("init datasource error, url: " + this.getUrl(), ex);
|
||||
connectError = ex;
|
||||
}
|
||||
|
||||
@@ -1768,7 +1768,7 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
try {
|
||||
connection = createPhysicalConnection();
|
||||
} catch (SQLException e) {
|
||||
LOG.error("create connection error", e);
|
||||
LOG.error("create connection error, url: " + jdbcUrl, e);
|
||||
|
||||
errorCount++;
|
||||
|
||||
@@ -1843,7 +1843,7 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
try {
|
||||
connection = createPhysicalConnection();
|
||||
} catch (SQLException e) {
|
||||
LOG.error("create connection error", e);
|
||||
LOG.error("create connection error, url: " + jdbcUrl, e);
|
||||
|
||||
errorCount++;
|
||||
|
||||
@@ -2635,7 +2635,7 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
Connection conn = createPhysicalConnection();
|
||||
holder = new DruidConnectionHolder(this, conn);
|
||||
} catch (SQLException e) {
|
||||
LOG.error("fill connection error", e);
|
||||
LOG.error("fill connection error, url: " + this.jdbcUrl, e);
|
||||
connectErrorCount.incrementAndGet();
|
||||
throw e;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user