Illegal access: this web application instance has been stopped already. Could not load com.mchange.v2.resourcepool.BasicResourcePool$1DestroyResourceTask. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.java.lang.IllegalStateException
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1566)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1526)
at com.mchange.v2.resourcepool.BasicResourcePool.destroyResource(BasicResourcePool.java:980)
at com.mchange.v2.resourcepool.BasicResourcePool.removeResource(BasicResourcePool.java:1406)
at com.mchange.v2.resourcepool.BasicResourcePool.removeResource(BasicResourcePool.java:1378)
at com.mchange.v2.resourcepool.BasicResourcePool.cullExpired(BasicResourcePool.java:1462)
at com.mchange.v2.resourcepool.BasicResourcePool.access$1900(BasicResourcePool.java:32)
at com.mchange.v2.resourcepool.BasicResourcePool$CullTask.run(BasicResourcePool.java:1937)
at java.util.TimerThread.mainLoop(Timer.java:555)
at java.util.TimerThread.run(Timer.java:505)
If you think there is no problem with the code, you can try changing to a different version of tomcat, such as 8.0 or 8.5.
Tomcat9 seems to have some problems at the moment. I tried it two weeks ago and it can’t run
tomcat reports an exception Illegal access: this web application instance has been stopped already. Could not load exception information cannot reflect the root cause of the system startup failure. When encountering such exceptions, many developers may be a little overwhelmed because they don't know where the problem occurs. Here is a trick to help you accurately locate the reason why the tomcat system fails to start.
1. Prepare a configuration file, the name must be: logging.properties.
The content of the file is as follows:
Place this file logging.properties under web-inf/classes of the java web project
Restart Tomcat
At this time, you will find that tomcat automatically prints more useful exception information. By analyzing these newly printed abnormal information, you can immediately locate the problem.