mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
DruidDataSource支持Filter
git-svn-id: http://code.alibabatech.com/svn/druid/trunk@52 b9813039-fb51-4c41-a8b9-e21c2acb5095
This commit is contained in:
@@ -90,6 +90,14 @@ public class DruidDataSource extends DruidDataAbstractSource implements DruidDat
|
||||
if (inited) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (maxActive <= 0) {
|
||||
throw new IllegalArgumentException("illegal maxActive " + maxActive);
|
||||
}
|
||||
|
||||
if (maxIdle <= 0 || maxIdle < minIdle) {
|
||||
throw new IllegalArgumentException("illegal maxPoolSize");
|
||||
}
|
||||
|
||||
if (this.driverClass != null) {
|
||||
this.driverClass = driverClass.trim();
|
||||
@@ -119,10 +127,6 @@ public class DruidDataSource extends DruidDataAbstractSource implements DruidDat
|
||||
|
||||
initConnectionFactory();
|
||||
|
||||
if (maxIdle <= 0 || maxIdle < minIdle) {
|
||||
throw new IllegalArgumentException("illegal maxPoolSize");
|
||||
}
|
||||
|
||||
int capacity = maxIdle + maxActive;
|
||||
|
||||
if (capacity < getInitialSize()) {
|
||||
|
||||
Reference in New Issue
Block a user