0

I'm running a Java app in Eclipse EE Oxygen 32 bit in a 64 machine since the program will be transferred to a 32 bit machine later. The app is connected to mysql installed through Wampserver, and the server I'm using in the app is Apache Tomcat 8.0.35. When I run the app in "Run as> Run on Server" inside Eclispe. I get the following error message in "Console":

 Illegal access: this web application instance has been stopped already. Could not load []. The following stack trace is thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access.
java.lang.IllegalStateException: Illegal access: this web application instance has been stopped already. Could not load []. The following stack trace is thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access.
    at org.apache.catalina.loader.WebappClassLoaderBase.checkStateForResourceLoading(WebappClassLoaderBase.java:1372)
    at org.apache.catalina.loader.WebappClassLoaderBase.getResource(WebappClassLoaderBase.java:1042)
    at com.mysql.jdbc.AbandonedConnectionCleanupThread.checkContextClassLoaders(AbandonedConnectionCleanupThread.java:90)
    at com.mysql.jdbc.AbandonedConnectionCleanupThread.run(AbandonedConnectionCleanupThread.java:63)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)

How can I debug that?

halfer
  • 19,824
  • 17
  • 99
  • 186
E. AMARAL
  • 949
  • 1
  • 10
  • 20
  • I must use it because of compatibility with other libraries connected to the project, but would the version (32 bit Eclipse in 64 bit machine) be causing the problem? – E. AMARAL Nov 24 '18 at 18:46
  • No, see my answer: just restart Tomcat then try again. –  Nov 24 '18 at 18:52
  • Please read [Under what circumstances may I add “urgent” or other similar phrases to my question, in order to obtain faster answers?](//meta.stackoverflow.com/q/326569) - the summary is that this is not an ideal way to address volunteers, and is probably counterproductive to obtaining answers. Please refrain from adding this to your questions. – halfer Nov 25 '18 at 22:08

1 Answers1

0

The java code is totally portable across 32-bit and 64-bit platforms, doesn't make sense to use a 32 bit Eclipse version.

To solve your issue, just restart the Tomcat server to get rid of the older cache then try again.

If still doesn't work:

  1. Restart Eclipse
  2. Clean up Eclipse working directory (see @nitind comment).
  3. Run Eclipse in clean mode (see this)
  • 1
    You can also clear out the work directory from the instance's context menu in the **Servers** view. – nitind Nov 24 '18 at 19:02
  • I went to "tomcat/bin" and run "shutdown.bat" (I'm using Windows) , and than run "start.bat". But still the same error returned. – E. AMARAL Nov 24 '18 at 19:03