mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
improved monitor.
This commit is contained in:
@@ -118,7 +118,7 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
private long notEmptySignalCount = 0L;
|
||||
private long notEmptyWaitNanos = 0L;
|
||||
|
||||
private int keepAliveCheckCount = 0;
|
||||
private int keepAliveCheckCount = 0;
|
||||
|
||||
private int activePeak = 0;
|
||||
private long activePeakTime = 0;
|
||||
@@ -331,6 +331,24 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
this.setPoolPreparedStatements0(value);
|
||||
}
|
||||
}
|
||||
{
|
||||
Boolean value = getBoolean(properties, "druid.initVariants");
|
||||
if (value != null) {
|
||||
this.setInitVariants(value);
|
||||
}
|
||||
}
|
||||
{
|
||||
Boolean value = getBoolean(properties, "druid.initGlobalVariants");
|
||||
if (value != null) {
|
||||
this.setInitGlobalVariants(value);
|
||||
}
|
||||
}
|
||||
{
|
||||
Boolean value = getBoolean(properties, "druid.useUnfairLock");
|
||||
if (value != null) {
|
||||
this.setUseUnfairLock(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isUseGlobalDataSourceStat() {
|
||||
@@ -2835,6 +2853,14 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
dataMap.put("MinEvictableIdleTimeMillis", this.getMinEvictableIdleTimeMillis());
|
||||
dataMap.put("MaxEvictableIdleTimeMillis", this.getMaxEvictableIdleTimeMillis());
|
||||
|
||||
dataMap.put("LogDifferentThread", isLogDifferentThread());
|
||||
dataMap.put("RecycleErrorCount", getRecycleErrorCount());
|
||||
dataMap.put("PreparedStatementOpenCount", getPreparedStatementCount());
|
||||
dataMap.put("PreparedStatementClosedCount", getClosedPreparedStatementCount());
|
||||
|
||||
dataMap.put("UseUnfairLock", isUseUnfairLock());
|
||||
dataMap.put("InitGlobalVariants", isInitGlobalVariants());
|
||||
dataMap.put("InitVariants", isInitVariants());
|
||||
return dataMap;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user