VisualVM
  1. VisualVM
  2. VISUALVM-224

Cannot memory profile JBoss AS 4.2.3.GA

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Blocker Blocker
    • Resolution: Unresolved
    • Affects Version/s: 1.0.1
    • Fix Version/s: 1.2
    • Component/s: code
    • Labels:
      None
    • Environment:

      Operating System: Windows XP
      Platform: All

    • Issuezilla Id:
      224

      Description

      Activating memory profiling renders the connected JBoss AS instance unusable
      with the following stack trace on every page of all applications:

      Profiler Agent Warning: Failed to lookup cached class javax/servlet/ServletException
      16:33:53,750 ERROR [[default]] Servlet.service() for servlet default threw exception
      java.lang.ClassNotFoundException: No ClassLoaders found for:
      org.netbeans.lib.profiler.server.ProfilerRuntimeObjLiveness
      at org.jboss.mx.loading.LoadMgr3.beginLoadTask(LoadMgr3.java:320)
      at
      org.jboss.mx.loading.RepositoryClassLoader.loadClassImpl(RepositoryClassLoader.java:533)
      at
      org.jboss.mx.loading.RepositoryClassLoader.loadClass(RepositoryClassLoader.java:423)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
      at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
      at
      org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:238)
      at
      org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
      at
      org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      at
      org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:238)
      at
      org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
      at
      org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
      at
      org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:177)
      at
      org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:188)
      at
      org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:438)
      at
      org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
      at
      org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
      at
      org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
      at
      org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:163)
      at
      org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
      at
      org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
      at
      org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
      at
      org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
      at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
      at java.lang.Thread.run(Thread.java:619)

      Steps to reproduce:
      1. Deploy any Seam example application (i.e. Booking) to JBoss AS
      2. Connect Visual VM console to the running JBoss AS instance
      3. Profiler -> Memory, wait patiently to instrument all classes, clicking "no"
      when prompted to disconnect because application hasn't responded yet.
      4. Access any page on from the application server.

      Live results are recorded and all the classes appear to be instrumented (visible
      via the console and "Profiler Agent" output). However, the instrumentation
      appears to have broken a class somewhere. Any ideas on why this might have
      occurred?

      JBoss Seam 2.0.3.CR1
      JBoss AS 4.2.3.GA
      Windows XP SP3

        Activity

        Hide
        rholder added a comment -

        It's also an issue with the version of VisualVM that ships with the JDK 1.6.0_10.

        Show
        rholder added a comment - It's also an issue with the version of VisualVM that ships with the JDK 1.6.0_10.
        Hide
        rholder added a comment -

        Created an attachment (id=95)
        Log file for VisualVM that ships with Sun JDK 1.6.0_10

        Show
        rholder added a comment - Created an attachment (id=95) Log file for VisualVM that ships with Sun JDK 1.6.0_10
        Hide
        mosabua added a comment -

        Probably related to issue 208

        Show
        mosabua added a comment - Probably related to issue 208
        Hide
        yardus added a comment -

        Could you try supplying JAVA_OPTS=-XX:MaxPermSize=200m to JBoss?

        It seems that the permgen space is getting depleted and that makes the profiled
        process to fail.

        Show
        yardus added a comment - Could you try supplying JAVA_OPTS=-XX:MaxPermSize=200m to JBoss? It seems that the permgen space is getting depleted and that makes the profiled process to fail.
        Hide
        wayfarer3130 added a comment -

        I've tried this with MaxPermSize=256m and it makes no difference whatsoever.
        I expect this issue is that the classloader that manages the web archives isn't the one that was used to load ProfilerRuntimeObjLiveness and that causes the object to be unuseable once it has been rewritten. It might be possible to drop the class into the global classpath and get things running that way.

        Show
        wayfarer3130 added a comment - I've tried this with MaxPermSize=256m and it makes no difference whatsoever. I expect this issue is that the classloader that manages the web archives isn't the one that was used to load ProfilerRuntimeObjLiveness and that causes the object to be unuseable once it has been rewritten. It might be possible to drop the class into the global classpath and get things running that way.
        Hide
        wayfarer3130 added a comment -

        My previous comment was correct. If you drop jfluid-server.jar into server/default/lib (or the appropriate instance in jboss if not default instance), then VisualVM works fine and the application works fine.

        Show
        wayfarer3130 added a comment - My previous comment was correct. If you drop jfluid-server.jar into server/default/lib (or the appropriate instance in jboss if not default instance), then VisualVM works fine and the application works fine.

          People

          • Assignee:
            yardus
            Reporter:
            rholder
          • Votes:
            3 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated: