commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Phil Steitz <phil.ste...@gmail.com>
Subject Re: [DBCP]a question about ManualPoolingDriverExample
Date Sun, 29 Sep 2013 16:09:35 GMT
Good question, Li Li.  The answer is no, this is done by the
PoolableConnectionFactory constructor.  You can see that in the
source here:
http://svn.apache.org/repos/asf/commons/proper/dbcp/branches/DBCP_1_3_x_BRANCH/src/java/org/apache/commons/dbcp/PoolableConnectionFactory.java.

Phil

On 9/28/13 10:09 PM, Li Li wrote:
> hi all
>     I am using DBCP as a connection pool using codes like
> http://svn.apache.org/repos/asf/commons/proper/dbcp/branches/DBCP_1_3_x_BRANCH/doc/ManualPoolingDriverExample.java
>
>    there is a line:  PoolableConnectionFactory
> poolableConnectionFactory = new
> PoolableConnectionFactory(connectionFactory,connectionPool,null,null,false,true);
>
>    it creates a PoolableConnectionFactory but never use it.
>
>    do I need add this? connectionPool.setFactory(poolableConnectionFactory);
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
> For additional commands, e-mail: user-help@commons.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org


Mime
View raw message