This content has been marked as final.
Show 1 reply
-
1. Re: database heartbeats
davidjencks May 1, 2002 12:54 AM (in response to attacksub)You can't do this right now.
I don't understand why you would want to. Connections can fail at any time whether they are being used or not. Checking them won't make them less likely to fail.
What you can do is set the idle timeout so, if you know the database closes unused connnections on you after x minutes, jboss will close unused connections sooner. Set the idletimeout <= x * 2 / 3. (these instructions are for jboss 3)
If you really need to do this, using jboss 3 you can implement your own managed connection pool and plug it into the connection manager mbean. Your pool can start a thread to go through the pooled connections and check them.