I experienced a similar problem in an application that I was developing.  I was using 
a MySQL database though.  I solved the problem by adding:

    ?autoReconnect=true

to the JDBC URL.

That said, I also upgraded my MySQL Connector to 3.0.9 becase a colleague noticed this 
comment in the ChangeLog http://www.mysql.com/downloads/api-jdbc-stable.html

"Don't fire connection closed events when closing pooled connections, or on 
PooledConnection.getConnection() with already open connections (BUG#884)."

HTH,
Andy

> -----Original Message-----
> From: Mike Zatko [mailto:[EMAIL PROTECTED] 
> Sent: Monday, January 26, 2004 6:22 AM
> To: Jakarta Commons Users List
> Subject: Re: [DBCP] Hanging
> 
> Dirk Verbeeck wrote:
> 
> > Some questions:
> > What is the DBCP configuration you use? DriverManager?
> > Are there network connection between you application and 
> the database 
> > when the getConnection hangs?
> > How much idle time?
> >
> > -- Dirk
> >
> > Mike Zatko wrote:
> >
> >> Hello,
> >>    I am using DBCP to connect to a MySQL 4.0.14-max-nt 
> database. The 
> >> program is a web application. It works fine until the app 
> sits idle 
> >> for a period of time. When that happens, my call to the 
> DriverManager 
> >> for a getConnection just hangs indefinately. No error or anything.
> >> Does anyone have an idea of how to prevent this?
> >>
> >> Thanks,
> >> Mike
> >
> >
> >
> >
> >
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: 
> [EMAIL PROTECTED]
> >
> >
> Does anybody have any idea why I send messages to this list 
> and they only "go through" like maybe 1 out of 10 times? Is 
> there something special you have to do to guarantee that a 
> message gets posted?
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to