Announcement Announcement Module
No announcement yet.
IllegalStateException with no error description Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • IllegalStateException with no error description

    I am working on a webapp where I am instantiating a session-scoped bean that connects to RMI. I am injecting this bean into many of my service objects so that they can make function calls without worrying about the connection (I am forced to use the company's method of connecting to RMI for the time being, so I can't use the Spring module). It appeared to work at first, however, I keep getting this error in my log from time to time:

    INFO: Illegal access: this web application instance has been stopped already.  Could not load$2.  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.
            at org.apache.catalina.loader.WebappClassLoader.loadClass(
            at org.apache.catalina.loader.WebappClassLoader.loadClass(
            at java.lang.ClassLoader.loadClassInternal(
            at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.getTarget(
            at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(
            at com.isdm.rmibeans.RMISubmissionManagerController$$EnhancerByCGLIB$$2f8e0bc6.finalize(<generated>)
            at java.lang.ref.Finalizer.invokeFinalizeMethod(Native Method)
            at java.lang.ref.Finalizer.runFinalizer(
            at java.lang.ref.Finalizer.access$100(
            at java.lang.ref.Finalizer$
    Note that RMISubmissionManagerController is the session-scoped bean that I'm instantiating. Apparently, it's finalize method is causing this error. I was under the impression that when an IllegalStateException occurs, there was an error description that gave more detail into what caused it, but this error doesn't have that. Any idea what could be causing it? How can I avoid this error? Thanks.

  • #2
    I'm still having problems with this. I changed reloadable from "true" to "false" in my context.xml, as suggested by some other forums, but I still get the error. Any help would be appreciated.


    • #3
      It seems that your RMISubmissionManagerController has an overridden finalize() method, and Spring's Cglib2AopProxy doesn't properly detect this. I've fixed Cglib2AopProxy to not dispatch such an overridden "finalize()" method either, handling it locally and hence not triggering further loading of classes.

      This will be available in tonight's 2.5.2 snapshot.