[ 
https://issues.apache.org/jira/browse/DBCP-300?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12754698#action_12754698
 ] 

Phil Steitz commented on DBCP-300:
----------------------------------

A workaround is to "manually" construct a PoolingDataSource as in the 
ManualPoolingDataSourceExample linked under Examples on the dbcp home page.  

This issue will be a little tricky to "fix" given the lazy initialization and 
(supposed) property mutability of BasicDataSource.  One thing we should 
consider is deprecating BasicDataSource and replacing it with a class whose 
properties (other than closed) are immutable.

> remove synchronize access of createDataSource
> ---------------------------------------------
>
>                 Key: DBCP-300
>                 URL: https://issues.apache.org/jira/browse/DBCP-300
>             Project: Commons Dbcp
>          Issue Type: Improvement
>    Affects Versions: 1.2.2
>         Environment: RHEL, jdk1.5.0_12, commons-dbcp 1.2.2
>            Reporter: Nikhil Singh
>
> For JDK1.5 onwards we can make the DataSource volatile and start using 
> "double checked locking" idiom. In my performance testing I have already 
> started seeing wait time on this lock. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to