mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
ha
This commit is contained in:
@@ -108,8 +108,6 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
|
||||
private String initStackTrace;
|
||||
|
||||
private ObjectName objectName;
|
||||
|
||||
public DruidDataSource(){
|
||||
}
|
||||
|
||||
@@ -117,14 +115,6 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
return initStackTrace;
|
||||
}
|
||||
|
||||
public ObjectName getObjectName() {
|
||||
return objectName;
|
||||
}
|
||||
|
||||
public void setObjectName(ObjectName objectName) {
|
||||
this.objectName = objectName;
|
||||
}
|
||||
|
||||
public boolean isResetStatEnable() {
|
||||
return resetStatEnable;
|
||||
}
|
||||
@@ -703,7 +693,9 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
|
||||
for (;;) {
|
||||
if (poolingCount == 0) {
|
||||
empty.signal(); // send signal to CreateThread create connection
|
||||
if (notEmptyWaitThreadCount == 0) {
|
||||
empty.signal(); // send signal to CreateThread create connection
|
||||
}
|
||||
|
||||
if (estimate <= 0) {
|
||||
throw new GetConnectionTimeoutException();
|
||||
@@ -712,9 +704,7 @@ public class DruidDataSource extends DruidAbstractDataSource implements DruidDat
|
||||
notEmptyWaitThreadCount++;
|
||||
try {
|
||||
long startEstimate = estimate;
|
||||
estimate = notEmpty.awaitNanos(estimate); // signal by
|
||||
// recycle or
|
||||
// creator
|
||||
estimate = notEmpty.awaitNanos(estimate); // signal by recycle or creator
|
||||
notEmptyWaitCount++;
|
||||
notEmptyWaitNanos += (startEstimate - estimate);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user