Developer looses database connection overnight?

I was having problems disabling MySQLs timeout, so took that issue to a mysql list.

The response there (from, AFAIK, the MySQL Connector/J author) was that the correct solution is for Servoy to handle the timeout (or any other interuption to the JDBC connection) gracefully:

JDBC connections aren’t guaranteed to last forever (I even checked with
the JDBC spec lead on this).

You need to make sure your application has the ‘smarts’ to handle
connection failure, and re-connect and retry the transaction (if it makes
sense), or mark the current connection as bad, pass the exception up the
stack, and re-establish the connection later.

Connections don’t go away just because of wait_timeout, someone might
unplug a switch, restart the database server, ifconfig an interface down,
router flakes out…There are many potential failure scenarios for a
network connection, and only your application will know what the prudent
action to take (retry immediately, throw error retry later, shutdown, etc0
is.
[…]

Archived at: http://marc.theaimsgroup.com/?l=mysql&m … 912005&w=2

A bit more rummaging around turned up this in the Connector/J README file:

Issue:

“I have a servlet/application that works fine for a day, and then stops
working overnight”.

Resolution:

MySQL closes connections after 8 hours of inactivity. You either
need to use a connection pool that handles stale connections or use the
“autoReconnect” parameter (see “USAGE AND INSTALLATION”). Also, you should
be catching SQLExceptions in your application and dealing with them,
[…]

Obviously there’s a difference of opinion here :-(

Any chance you could take this up with Mark Matthews mark@mysql.com ?

Thanks,
Neale.