mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
improved for create scheduler
This commit is contained in:
@@ -1762,14 +1762,13 @@ public class DruidDataSource extends DruidAbstractDataSource
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
runInternal();
|
||||
}
|
||||
|
||||
private void runInternal() {
|
||||
for (;;) {
|
||||
// addLast
|
||||
try {
|
||||
lock.lockInterruptibly();
|
||||
} catch (InterruptedException e2) {
|
||||
break;
|
||||
}
|
||||
|
||||
lock.lock();
|
||||
try {
|
||||
// 必须存在线程等待,才创建连接
|
||||
if (poolingCount >= notEmptyWaitThreadCount) {
|
||||
|
||||
Reference in New Issue
Block a user