2 Replies Latest reply on Jan 19, 2007 6:14 PM by Ben Wang

    NoSuchMethodError: javassist.CtClass.stopPruning(Z)

    Jamie Reifsnyder Newbie

      Hi everybody,
      My previous post contained configuration info for a build error I'm getting, but incorrectly pointed to the error that was the problem.

      After working another couple hours, I have the following config on JBoss 4.0.5GA,jboss-aop 1.5.2GA, and JBossCache 1.4.1GA.

      Pojo class
      @org.jboss.cache.aop.annotation.PojoCacheable
      public class ChatSubscriber implements java.io.Serializable {
      private TopicConnection topicConnection;
      private TopicSession topicSession;
      private Topic topic;
      private TopicSubscriber receiver;
      @org.jboss.cache.aop.annotation.Transient String message;
      etc.}

      jboss-aop.xml

      <aop>
       <prepare expr="field(* @org.jboss.cache.aop.AopMarker->*)" />
       <prepare expr="field(* $instanceof{@org.jboss.cache.aop.InstanceOfAopMarker}->*)" />
       <prepare expr="field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)" />
       <prepare expr="field(* $instanceof{@org.jboss.cache.aop.annotation.InstanceOfPojoCacheable}->*)" />
      </aop>


      build.xml
      <aopc compilerclasspathref="classpath" verbose="true">
       <classpath path="${cache.classes.dir}"/>
       <src path="${cache.classes.dir}"/> <!-- -->
       <include name="**/ChatSubscriber.class"/>
       <aoppath path="META-INF/jboss-aop.xml"/>
       <aopclasspath path="${cache.classes.dir}"/>
       </aopc>


      and when I run aopc, I get the following error:
      [aopc] [debug] Passed in instrumentor: null
      [aopc] [debug] Defaulting instrumentor to: org.jboss.aop.instrument.ClassicInstrumentor
      [aopc] [debug] jboss.aop.class.path: C:\Zen_chat\ChatSample\server\Chat\lib\WEB-INF\classes
      [aopc] [debug] Looking for aspects in: oracle.otnsamples.oc4jjms.ChatItem
      [aopc] [debug] Looking for aspects in: oracle.otnsamples.oc4jjms.ChatPublisher
      [aopc] [debug] Looking for aspects in: oracle.otnsamples.oc4jjms.ChatSubscriber
      [aopc] [debug] Looking for aspects in: oracle.otnsamples.oc4jjms.GetMessage
      [aopc] [debug] Looking for aspects in: oracle.otnsamples.oc4jjms.SendMessage
      [aopc] [debug] jboss.aop.search.classpath: 'null' true
      [aopc] [debug] jboss.aop.path: C:\Zen_chat\ChatSample\server\Chat\META-INF\jboss-aop.xml
      [aopc] jboss.aop.path[0]: C:\Zen_chat\ChatSample\server\Chat\META-INF\jboss-aop.xml
      [aopc] [deploying] file:/C:/Zen_chat/ChatSample/server/Chat/META-INF/jboss-aop.xml
      [aopc] [trying to transform] oracle.otnsamples.oc4jjms.ChatSubscriber
      [aopc] [debug] There are no caller pointcuts!
      [aopc] [debug] javassist.CtMethod@5b799e78[public getTopicConnection ()Ljavax/jms/TopicConnection;] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@2be7c174[public setTopicConnection (Ljavax/jms/TopicConnection;)V] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@357fbe9e[public getTopicSession ()Ljavax/jms/TopicSession;] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@b078985a[public setTopicSession (Ljavax/jms/TopicSession;)V] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@f9e57e3a[public getTopic ()Ljavax/jms/Topic;] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@deff1b74[public setTopic (Ljavax/jms/Topic;)V] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@fc63b182[public getTopicSubscriber ()Ljavax/jms/TopicSubscriber;] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@d55e2b34[public setTopicSubscriber (Ljavax/jms/TopicSubscriber;)V] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@ccbfbf43[public createSubscriber (Ljavax/naming/Context;Ljava/lang/String;Ljava/lang/String;)V] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@1ba8c6b5[public announcethyself (Ljava/lang/String;Ljava/lang/String;)V] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@a9989092[public getMessage ()Ljava/lang/String;] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@a2d029fc[public setMessage (Ljava/lang/String;)V] matches no pointcuts
      [aopc] [debug] javassist.CtMethod@b41642a5[public cleanup ()V] matches no pointcuts
      [aopc] [debug] javassist.CtConstructor@15f5897[public ChatSubscriber ()V] matches no pointcuts
      [aopc] [debug] javassist.CtConstructor@1cfb549[public ChatItem (Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V] matches no pointcuts
      [aopc] [debug] javassist.CtConstructor@186d4c1[public ChatPublisher ()V] matches no pointcuts
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.message:Ljava/lang/String; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.receiver:Ljavax/jms/TopicSubscriber; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.topic:Ljavax/jms/Topic; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.topicConnection:Ljavax/jms/TopicConnection; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.topicSession:Ljavax/jms/TopicSession; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.message:Ljava/lang/String; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.receiver:Ljavax/jms/TopicSubscriber; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.topic:Ljavax/jms/Topic; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.topicConnection:Ljavax/jms/TopicConnection; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] [debug] oracle.otnsamples.oc4jjms.ChatSubscriber.topicSession:Ljavax/jms/TopicSession; matches pointcut: field(* @org.jboss.cache.aop.annotation.PojoCacheable->*)
      [aopc] java.lang.NoSuchMethodError: javassist.CtClass.stopPruning(Z)V
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer$OptimizedTransformer.createOptimizedInvocationClass(FieldAccessTransformer.java:857)
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer$OptimizedTransformer.buildFieldWrappers(FieldAccessTransformer.java:533)
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer.buildFieldWrappers(FieldAccessTransformer.java:73)
      [aopc] at org.jboss.aop.instrument.Instrumentor.transform(Instrumentor.java:657)
      [aopc] at org.jboss.aop.AspectManager.translate(AspectManager.java:792)
      [aopc] at org.jboss.aop.AspectManager.transform(AspectManager.java:704)
      [aopc] at org.jboss.aop.standalone.Compiler.compileFile(Compiler.java:329)
      [aopc] at org.jboss.aop.standalone.Compiler.compile(Compiler.java:218)
      [aopc] at org.jboss.aop.standalone.Compiler.main(Compiler.java:74)
      [aopc] java.lang.RuntimeException: failed to transform: oracle.otnsamples.oc4jjms.ChatSubscriber
      [aopc] at org.jboss.aop.instrument.Instrumentor.transform(Instrumentor.java:704)
      [aopc] at org.jboss.aop.AspectManager.translate(AspectManager.java:792)
      [aopc] at org.jboss.aop.AspectManager.transform(AspectManager.java:704)
      [aopc] at org.jboss.aop.standalone.Compiler.compileFile(Compiler.java:329)
      [aopc] at org.jboss.aop.standalone.Compiler.compile(Compiler.java:218)
      [aopc] at org.jboss.aop.standalone.Compiler.main(Compiler.java:74)
      [aopc] Caused by: java.lang.NoSuchMethodError: javassist.CtClass.stopPruning(Z)V
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer$OptimizedTransformer.createOptimizedInvocationClass(FieldAccessTransformer.java:857)
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer$OptimizedTransformer.buildFieldWrappers(FieldAccessTransformer.java:533)
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer.buildFieldWrappers(FieldAccessTransformer.java:73)
      [aopc] at org.jboss.aop.instrument.Instrumentor.transform(Instrumentor.java:657)
      [aopc] ... 5 more
      [aopc] Exception in thread "main" java.lang.RuntimeException: failed to transform: oracle.otnsamples.oc4jjms.ChatSubscriber
      [aopc] at org.jboss.aop.instrument.Instrumentor.transform(Instrumentor.java:704)
      [aopc] at org.jboss.aop.AspectManager.translate(AspectManager.java:792)
      [aopc] at org.jboss.aop.AspectManager.transform(AspectManager.java:704)
      [aopc] at org.jboss.aop.standalone.Compiler.compileFile(Compiler.java:329)
      [aopc] at org.jboss.aop.standalone.Compiler.compile(Compiler.java:218)
      [aopc] at org.jboss.aop.standalone.Compiler.main(Compiler.java:74)
      [aopc] Caused by: java.lang.NoSuchMethodError: javassist.CtClass.stopPruning(Z)V
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer$OptimizedTransformer.createOptimizedInvocationClass(FieldAccessTransformer.java:857)
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer$OptimizedTransformer.buildFieldWrappers(FieldAccessTransformer.java:533)
      [aopc] at org.jboss.aop.instrument.FieldAccessTransformer.buildFieldWrappers(FieldAccessTransformer.java:73)
      [aopc] at org.jboss.aop.instrument.Instrumentor.transform(Instrumentor.java:657)
      [aopc] ... 5 more

      Where is the NoSuchMethodError coming from??
      Thanks,
      Jamie