Subject Re: [Firebird-Java] Tomcat contexts and pooled connections
Author Rick Fincher
Hi Natal,

Can you clarify a little on the pool? Are you using DBCP with Tomcat or
Jaybird's pooling mechanism?

If you are using DBCP you can set an "abandonded connection" parameter t
clean up stuff like this. It is a workaround, but it can be helpful.
Instructions are in the Tomcat documentation under the "JNDI DataSource
How-To" under the heading "Preventing DB Connection Pool Leaks".

Hope this helps!

Rick

----- Original Message -----

> Hello,
>
> We're currently using the latest Firebird-Java driver release (with
> pooled connections) with Firebird 1.0.3 CS and Tomcat 4.
>
> Everything is working smoothly, except for the fact that when we restart
> a servlet context (via the Tomcat application manager), the connections
> are not returned to the pool (a 'netstat -a | grep "gds"' confirms
> this). Restarting the complete tomcat server solves the problem (returns
> all connections) but this is not desired as all our servlet-contexts
> will be offline for a second or 5. Reloading a context via the
> application manager is almost instantaneous.
>
> Is there a way to return the database connections to the pool when the
> servlet context is reloaded? I presume they're removed from memory and
> reloaded but different from restarting the tomcat server, the
> connections aren't returned.
>
> Greetings,
> Natal Vande Casteele
> Software Engineer
> Pocket and Soul