4 Replies Latest reply on Feb 10, 2006 4:14 PM by Rajesh Chandra

    Urgent:ClassCircularityError

    sasaa Newbie

      Hi All,

      We have written an application using JBoss- version 3.2.2RC3 with Axis 1.1 and Java version j2sdk1.4.1_02. We are running concurrent tests on this application and we are getting ClassCircularity error in different places in our code. For every run, we get this error in some different place. ( I have provided a trace for one of these instances).

      I have looked up the forum and understand that there was some bug in the way the class loaders were getting used in Java. (bug #4699981).

      Has this problem been fixed in Java or a workaround has been introduced in JBoss?

      This error is posing very serious problem for us, as it prevents the application to run beyond this point.

      Any help will be highly appreciated.

      thanks




      -----------------------
      Here is the exception:
      14:15:52,466 ERROR [STDERR] java.lang.ClassCircularityError: boolean_Helper
      14:15:52,466 ERROR [STDERR] at java.lang.Class.forName0(Native Method)
      14:15:52,486 ERROR [STDERR] at java.lang.Class.forName(Class.java:219)
      14:15:52,486 ERROR [STDERR] at org.apache.axis.utils.ClassUtils$2.run(ClassU
      tils.java:193)
      14:15:52,486 ERROR [STDERR] at java.security.AccessController.doPrivileged(N
      ative Method)
      14:15:52,486 ERROR [STDERR] at org.apache.axis.utils.ClassUtils.loadClass(Cl
      assUtils.java:171)
      14:15:52,486 ERROR [STDERR] at org.apache.axis.utils.ClassUtils.forName(Clas
      sUtils.java:112)
      14:15:52,486 ERROR [STDERR] at org.apache.axis.encoding.ser.BaseFactory.getM
      ethod(BaseFactory.java:107)
      14:15:52,506 ERROR [STDERR] at org.apache.axis.encoding.ser.BaseDeserializer
      Factory.getGetDeserializer(BaseDeserializerFactory.java:264)
      14:15:52,506 ERROR [STDERR] at org.apache.axis.encoding.ser.BaseDeserializer
      Factory.getSpecialized(BaseDeserializerFactory.java:173)
      14:15:52,506 ERROR [STDERR] at org.apache.axis.encoding.ser.BaseDeserializer
      Factory.getDeserializerAs(BaseDeserializerFactory.java:117)
      14:15:52,506 ERROR [STDERR] at org.apache.axis.encoding.ser.SimpleDeserializ
      erFactory.getDeserializerAs(SimpleDeserializerFactory.java:107)
      14:15:52,506 ERROR [STDERR] at org.apache.axis.encoding.DeserializationConte
      xtImpl.getDeserializer(DeserializationContextImpl.java:466)
      14:15:52,536 ERROR [STDERR] at org.apache.axis.encoding.DeserializationConte
      xtImpl.getDeserializerForType(DeserializationContextImpl.java:481)
      14:15:52,536 ERROR [STDERR] at org.apache.axis.encoding.ser.BeanDeserializer
      .getDeserializer(BeanDeserializer.java:458)
      14:15:52,536 ERROR [STDERR] at org.apache.axis.encoding.ser.BeanDeserializer
      .onStartChild(BeanDeserializer.java:278)
      14:15:52,536 ERROR [STDERR] at org.apache.axis.encoding.DeserializationConte
      xtImpl.startElement(DeserializationContextImpl.java:963)
      14:15:52,536 ERROR [STDERR] at org.apache.axis.message.SAX2EventRecorder.rep
      lay(SAX2EventRecorder.java:198)
      14:15:52,536 ERROR [STDERR] at org.apache.axis.message.MessageElement.publis
      hToHandler(MessageElement.java:722)
      14:15:52,546 ERROR [STDERR] at org.apache.axis.encoding.DeserializerImpl.sta
      rtElement(DeserializerImpl.java:404)
      14:15:52,546 ERROR [STDERR] at org.apache.axis.encoding.ser.BeanDeserializer
      .startElement(BeanDeserializer.java:165)
      14:15:52,546 ERROR [STDERR] at org.apache.axis.encoding.DeserializationConte
      xtImpl.startElement(DeserializationContextImpl.java:976)
      14:15:52,546 ERROR [STDERR] at org.apache.axis.message.SAX2EventRecorder.rep
      lay(SAX2EventRecorder.java:198)
      14:15:52,546 ERROR [STDERR] at org.apache.axis.message.MessageElement.publis
      hToHandler(MessageElement.java:722)
      14:15:52,546 ERROR [STDERR] at org.apache.axis.message.RPCElement.deserializ
      e(RPCElement.java:323)
      14:15:52,576 ERROR [STDERR] at org.apache.axis.message.RPCElement.getParams(
      RPCElement.java:347)
      14:15:52,576 ERROR [STDERR] at org.apache.axis.client.Call.invoke(Call.java:
      2272)
      14:15:52,576 ERROR [STDERR] at org.apache.axis.client.Call.invoke(Call.java:
      2171)
      14:15:52,576 ERROR [STDERR] at org.apache.axis.client.Call.invoke(Call.java:
      2196)
      14:15:52,576 ERROR [STDERR] at com.uniteller.switchcore.isc.impl.Communicato
      r.execute(Communicator.java:255)
      14:15:52,576 ERROR [STDERR] at com.uniteller.switchcore.isc.impl.Communicato
      r.run(Communicator.java:93)
      14:15:52,596 ERROR [STDERR] at java.lang.Thread.run(Thread.java:534)

        • 1. Re: Urgent:ClassCircularityError
          Scott Stark Master

          You'll have to upgrade to jboss-3.2.3 to find a fix. A workaround would be to load all classes in a single thread on startup.

          • 2. Re: Urgent:ClassCircularityError
            sasaa Newbie

            Thanks for that!

            It seems to work with Jboss 3.2.3

            • 3. Re: Urgent:ClassCircularityError
              Oystein Aadland Newbie

              Hi Scott (or anyone else that now about this)

              I'm experiensing the same problem as sasaa in JBoss 3.2.7. Could you tell me what you meen by loading all classes in the same thread on startup. In my case this happens in Tomcat/axis code on the server before my code is called. Do you meen that it is possible to load axis/tomcat in a single thread (if it is, please tell me how), or have I completely missed the point.

              Thank you

              Here is my stacktrace:

              java.lang.ClassCircularityError: java/lang/String_Helper
              java.lang.Class.forName0(Native Method)
              java.lang.Class.forName(Class.java:219)
              org.apache.axis.utils.ClassUtils$2.run(ClassUtils.java:200)
              java.security.AccessController.doPrivileged(Native Method)
              org.apache.axis.utils.ClassUtils.loadClass(ClassUtils.java:179)
              org.apache.axis.utils.ClassUtils.forName(ClassUtils.java:120)
              org.apache.axis.encoding.ser.BaseFactory.getMethod(BaseFactory.java:87)
              org.apache.axis.encoding.ser.BaseDeserializerFactory.getGetDeserializer(BaseDeserializerFactory.java:325)
              org.apache.axis.encoding.ser.BaseDeserializerFactory.getSpecialized(BaseDeserializerFactory.java:195)
              org.apache.axis.encoding.ser.BaseDeserializerFactory.getDeserializerAs(BaseDeserializerFactory.java:118)
              org.apache.axis.encoding.ser.SimpleDeserializerFactory.getDeserializerAs(SimpleDeserializerFactory.java:117)
              org.apache.axis.encoding.DeserializationContextImpl.getDeserializer(DeserializationContextImpl.java:575)
              org.apache.axis.message.RPCHandler.onStartChild(RPCHandler.java:308)
              org.apache.axis.encoding.DeserializationContextImpl.startElement(DeserializationContextImpl.java:1166)
              org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:244)
              org.apache.axis.message.SOAPElementAxisImpl.publishToHandler(SOAPElementAxisImpl.java:1387)
              org.apache.axis.message.RPCElement.deserialize(RPCElement.java:262)
              org.apache.axis.message.RPCElement.getParams(RPCElement.java:396)
              org.apache.axis.providers.java.RPCInvocation.prepareFromRequestEnvelope(RPCInvocation.java:234)
              org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:103)
              org.jboss.net.axis.server.EJBProvider.processMessage(EJBProvider.java:231)
              org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:358)
              org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:73)
              org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:160)
              org.apache.axis.SimpleChain.invoke(SimpleChain.java:123)
              org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:560)
              org.apache.axis.server.AxisServer.invoke(AxisServer.java:355)
              org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:975)
              javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
              org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:370)
              javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
              org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:75)

              <-- Client/server boundry

              My code

              • 4. Re: Urgent:ClassCircularityError
                Rajesh Chandra Newbie

                I am also getting the same error in 3.2.5 and 3.2.8 with JDK 1.4.2_05.