HSQLDB Timer Thread still running when servlet is destroyed2020-04-17 servlets hsqldb
I am developing a servlet running on Tomcat. While I am still in the early stages of development, I am testing against a flat-file HSQLDB database. Once I get closer to production readiness, I will move to HSQLDB in server mode (or maybe an entirely different DBMS, though this is yet to be decided).
Now every time Tomcat reloads the servlet (I am developing with Eclipse), I get the following message:
The web application [subscription-manager] appears to have started a thread named [HSQLDB Timer @1192be13] but has failed to stop it.
Answers indicate that I should issue a
SHUTDOWN command against the database to fix this—fair enough as long as it is only a flat-file DB but a recipe for disaster once I move to server mode (where the database will be shared between multiple components).
Should I just ignore this warning for now and expect it to go away when I switch to server mode, or will the HSQLDB driver still spawn the timer thread when connecting to an instance running in server mode? And if it does, what would I need to do?
You can ignore the warning if you are going to switch to server mode.
The driver does not spawn the Timer thread when connected to the database server. There will be a Timer thread on the server process.
- Apache Derby - Embedded Mode - Failed to start database while reloading a servlet
- When exactly a servlet is destroyed?
- Retrieving data from hsqldb using jsp and servlets
- Is it possible to change HSQLDB mode to read-only on the fly?
- HSQLDB .script file
- OSGi Servlet with HSQLDB
- Web application deployment under embedded Tomcat 7.0.32
- Should JDBC drivers be included in a WAR?
- Async data fetching from Java WebService