Merge branch 'dev-1.0' of Z:\static\source\sydapi-sge-database into dev-1.0

 Conflicts:
	src/main/java/com/sunyard/sge/pool/ThreadBasedConnectPool.java
This commit is contained in:
junj2.liang 2022-08-15 15:41:15 +08:00
commit 9fbebac1ea
2 changed files with 4 additions and 4 deletions

View File

@ -63,18 +63,18 @@ public class ThreadBasedConnectPool<T> {
continue; continue;
} }
boolean checkRet = false; boolean checkPass = false;
try { try {
l.lock(); l.lock();
checkRet = check(entry.getValue().getObject()); checkPass = check(entry.getValue().getObjectForCheck());
} catch (Exception e) { } catch (Exception e) {
checkRet = false; checkPass = false;
} }
finally { finally {
l.unlock(); l.unlock();
} }
if (checkRet) { if ( ! checkPass) {
log.debug("一个链接检查未通过"); log.debug("一个链接检查未通过");
// 检查未通过 // 检查未通过
it.remove(); it.remove();