修改minIdle策略

git-svn-id: http://code.alibabatech.com/svn/druid/trunk@420 b9813039-fb51-4c41-a8b9-e21c2acb5095
This commit is contained in:
wenshao
2011-07-13 08:17:08 +00:00
parent 1bf77f8dd2
commit b2f61a9459
3 changed files with 24 additions and 24 deletions
@@ -41,22 +41,22 @@ public class Case3 extends TestCase {
private long minEvictableIdleTimeMillis = 60000;
protected void setUp() throws Exception {
// jdbcUrl = "jdbc:fake:dragoon_v25masterdb";
// user = "dragoon25";
// password = "dragoon25";
// driverClass = "com.alibaba.druid.mock.MockDriver";
// connectionProperties = "connectSleep=3;executeSleep=0";
jdbcUrl = "jdbc:fake:dragoon_v25masterdb";
user = "dragoon25";
password = "dragoon25";
driverClass = "com.alibaba.druid.mock.MockDriver";
connectionProperties = "connectSleep=3;executeSleep=1";
jdbcUrl = "jdbc:mysql://10.20.153.104:3306/druid2";
user = "root";
password = "root";
driverClass = "com.mysql.jdbc.Driver";
// jdbcUrl = "jdbc:mysql://10.20.153.104:3306/druid2";
// user = "root";
// password = "root";
// driverClass = "com.mysql.jdbc.Driver";
}
public void test_perf() throws Exception {
for (int i = 0; i < 10; ++i) {
druid();
dbcp();
// dbcp();
// boneCP();
}
}
@@ -541,10 +541,10 @@ public class DruidDataSourceUIManager extends JFrame {
public void run() {
final int threadCount = 10;
final int LOOP_COUNT = 1000 * 100;
final int LOOP_COUNT = 1000 * 10;
final String sql = "SELECT 1";
final CountDownLatch startLatch = new CountDownLatch(1);
final CountDownLatch endLatch = new CountDownLatch(1);
final CountDownLatch endLatch = new CountDownLatch(threadCount);
for (int i = 0; i < threadCount; ++i) {
Thread thread = new Thread() {