mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
git-svn-id: http://code.alibabatech.com/svn/druid/trunk@41 b9813039-fb51-4c41-a8b9-e21c2acb5095
This commit is contained in:
@@ -40,8 +40,8 @@ public class Case1 extends TestCase {
|
||||
private int maxPoolSize = 2;
|
||||
private int maxActive = 2;
|
||||
private String validationQuery = "SELECT 1";
|
||||
private int threadCount = 2;
|
||||
private int loopCount = 5;
|
||||
private int threadCount = 2;
|
||||
private int loopCount = 5;
|
||||
|
||||
protected void setUp() throws Exception {
|
||||
jdbcUrl = "jdbc:fake:dragoon_v25masterdb";
|
||||
@@ -93,14 +93,14 @@ public class Case1 extends TestCase {
|
||||
}
|
||||
System.out.println();
|
||||
}
|
||||
|
||||
|
||||
public void test_2() throws Exception {
|
||||
BoneCPDataSource dataSource = new BoneCPDataSource();
|
||||
// dataSource.(10);
|
||||
// dataSource.setMaxActive(50);
|
||||
dataSource.setMinConnectionsPerPartition(minPoolSize);
|
||||
dataSource.setMaxConnectionsPerPartition(maxPoolSize);
|
||||
|
||||
|
||||
dataSource.setDriverClass(driverClass);
|
||||
dataSource.setJdbcUrl(jdbcUrl);
|
||||
dataSource.setStatementsCacheSize(100);
|
||||
@@ -112,7 +112,7 @@ public class Case1 extends TestCase {
|
||||
dataSource.setAcquireIncrement(5);
|
||||
dataSource.setIdleConnectionTestPeriod(0L);
|
||||
dataSource.setDisableConnectionTracking(true);
|
||||
|
||||
|
||||
for (int i = 0; i < loopCount; ++i) {
|
||||
p0(dataSource, "boneCP", threadCount);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user