You are creating a thread in your application which runs indefinitely when it is getting deployed and keeps running. May be you are starting a thread in the ContextListener
ex: ServletContextListener
. In your case, it may be MySql
driver causes this problem. If you set the option Build Automatically
in your IDE say Eclipse
. Whenever you make changes in your class file, your application will be compiled, build and deployed in the server again. The other thing you should note is if you have JDBC jar in your WEB-INF/lib, then move it to the tomcat server lib and restart the server. This helps in de-registering the JDBC driver in JVM level.then, you will not be getting this message
Check out this link, this will give you more options to resolve it.