[Biojava-dev] JDBCConnectionPool

S. Foote foote at nrcbsa.bio.nrc.ca
Wed May 12 21:42:51 EDT 2004


As Thomas mentioned, the BioSQL interfaces now use the Apache dbcp
connection pooling instead of the old JDBCConnectionPool although it was
left there for legacy sakes.
I agree with Thomas, it should probably be removed completely. Also, there
is a README.biosql which explains what's needed to get it working with
dbcp.

Simon

According to Thomas Down:
> 
> On 12 May 2004, at 02:12, Francois Pepin wrote:
> 
> > Hi everyone,
> >
> > what is happening with JDBCConnectionPool? The last commit (by mrp in
> > November) says it might be deprecated soon and the docs says a standard
> > should be found soon.
> >
> > The code for takeConnection() is a bit weird, because the code that
> > would check if we can reuse a connection is commented out, so a new
> > connection is created every time. It works, but it kinds of defeat the
> > purpose of the class.
> 
> It looks like this class was "broken" intentionally in CVS revision 
> 1.5, and has never been reinstated.  I'm not sure if there's much need, 
> either -- BioSQL is now using the javax.sql.DataSource-style connection 
> pooling.  The rewritten biojava-ensembl does too (and it never really 
> used the JDBCConnectionPool class from BioJava anyway, it had its own 
> version -- actually the original which later got copied into BioJava).
> 
> Does anyone know anything else which uses JDBCConnectionPool?
> 
> It's evil anyway.  I wrote it in the dark old days when the javax.sql 
> package wasn't a standard part of J2SE, and there wasn't an easily 
> available general purpose implementation.  It certainly shouldn't be 
> used for new code.
> 
> > I need to use connection pooling but I'm not sure if I'd be better to
> > try to fix that one or just use the Apache commons-dbcp
> > (http://jakarta.apache.org/commons/dbcp/).
> 
> 
> Yes, you're definitely better off using that.
> 
>        Thomas.
> 
> _______________________________________________
> biojava-dev mailing list
> biojava-dev at biojava.org
> http://biojava.org/mailman/listinfo/biojava-dev
> 



More information about the biojava-dev mailing list