This commit is contained in:
温少
2012-03-21 01:52:26 +08:00
parent 3d7d476e0d
commit c518d8f39e
19 changed files with 137 additions and 121 deletions
@@ -169,9 +169,8 @@ public class DruidDriver implements Driver, DruidDriverMBean {
}
}
DataSourceProxy oldDataSource = proxyDataSources.putIfAbsent(url, newDataSource); // 多线程处理需要
DataSourceProxy oldDataSource = proxyDataSources.putIfAbsent(url, newDataSource);
if (oldDataSource == null) {
// 放进去的线程负责注册MBean
if (config.isJmxOption()) {
JMXUtils.register("com.alibaba.druid:type=JdbcStat", JdbcStatManager.getInstance());
}