1 Reply Latest reply on Jun 8, 2006 9:04 AM by kabirkhan

    Which jar for javaagent with EJB embedded/standalone

      The latest distributions of the EJB standalone (jboss-EJB-3.0_Embeddable_ALPHA_8.zip) comes as 3 big jars.
      If a try and use;

      -javaagent:jboss-ejb3-all.jar

      I get;

      Failed to load Premain-Class manifest attribute from jboss-ejb3-all.jar

      If I use the jboss-aop-jdk50.jar from the AOP distribution its fine as long as this jar isn't also on the classpath with jboss-ejb3-all.jar, as in that case the AOP classes are included twice and things go a bit strange.

      Shouldn't we be able to call -javaagent:jboss-ejb3-all.jar ?

      regards

      James

        • 1. Re: Which jar for javaagent with EJB embedded/standalone
          kabirkhan

          It's been a while since I looked at the embedded ejb 3 stuff, so I don't know how it is all packaged now, but all the magic takes place in the META-INF/MANIFEST.MF file of jboss-aop-jdk50.jar.

          The interesting entries are

          Premain-Class: org.jboss.aop.standalone.Agent
          Can-Redefine-Classes: true
          


          So try adding these attributes to the MANIFEST.MF of the jboss-ejb3-all.jar