MySQL connection problems on Tomcat
- From: Hakan <H.L@xxxxxxxxxxxx>
- Date: Fri, 20 Jun 2008 20:04:15 +0200
My web start application connects to a MySQL database through a servlet. The servlet accesses the database through a MySQL connector instance and returns the results the client if necessary. Everything is done through a Tomcat Linux web server.
My problems seem to occur when I run the program through the servlet for the first time after a while, like the first time of the day or after not testing it on the server for some days. It can't fetch anything from the database, so the client just gets null objects back. Ultimately, a NullPointerException kills the application as it has nothing to work with.
The solution is very simple. I shut down Tomcat and restart it, after which it again reads results from the database as it should. This is just not a sustainable way to deal with it.
My employer wants to deploy it such that many different users will have an interest in accessing it from various places and not just people with system administrator privileges. Hence, crashes are liable to make them spurn the application. That would make quite a lot of work useless.
Do you know the source of the mentioned problem?
Regards.
--
Newsoffice.de - Die Onlinesoftware zum Lesen und Schreiben im Usenet Die Signatur läßt sich nach Belieben anpassen ;-)
.
- Follow-Ups:
- Re: MySQL connection problems on Tomcat
- From: David Harper
- Re: MySQL connection problems on Tomcat
- From: joeNOSPAM@xxxxxxx
- Re: MySQL connection problems on Tomcat
- From: Arne Vajhøj
- Re: MySQL connection problems on Tomcat
- Prev by Date: Re: Books to advance my learning
- Next by Date: Re: MySQL connection problems on Tomcat
- Previous by thread: Ryhmän sfnet.tiede.tietotekniikka virallinen kuvaus
- Next by thread: Re: MySQL connection problems on Tomcat
- Index(es):
Relevant Pages
|