3 Replies Latest reply on Nov 23, 2004 3:49 AM by rajdeep_dua

    XDoclet CMP2 Exception

    cahaverl

      I'm running into an xdoclet exception "Unknown jboss version number for cmp2 2.4" under CMP2 which prevents the generation of jaws.xml.
      Has anyone figured out how to deal with this short of installing a version older than the JBoss 3.2.3 I'm using, or fixing the source and rebuilding JBoss IDE?

      I get

      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE jaws PUBLIC "-//JBoss//DTD JBOSS 2.4//EN" "http://www.jboss.org/j2ee/dtd/jboss_2_4.dtd">
      
      <jaws>
       <datasource>java:/DefaultDS</datasource>
       <type-mapping>Hypersonic SQL</type-mapping>
       <debug>false</debug>
      
       <enterprise-beans>
      
       </enterprise-beans>
      
      </jaws>


      instead of a longer file spelling out my field-column-type mappings. I'm specifying CMP2 with this:

      * @ejb.bean name = "Item"
       * jndi-name = "ItemBean"
       * type = "CMP"
       * primkey-field = "itemID"
       * schema = "MyStoreItem"
       * cmp-version = "2.x"


      Here is the exception itself:

      [ejbdoclet] (XDocletMain.start 47 ) Running jboss
       [ejbdoclet] (XDocletMain.start 53 ) Running XDoclet failed.
       [ejbdoclet] (XDocletMain.start 54 ) <<Unknown jboss version number for cmp2 2.4>>
       [ejbdoclet] file:C:/Carl/Eclipse/MyStore/xdoclet-build.xml:13: XDoclet failed.
       [ejbdoclet] at xdoclet.DocletTask.start(DocletTask.java:461)
       [ejbdoclet] at xjavadoc.ant.XJavadocTask.execute(XJavadocTask.java:95)
       [ejbdoclet] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:193)
       [ejbdoclet] at org.apache.tools.ant.Task.perform(Task.java:341)
       [ejbdoclet] at org.apache.tools.ant.Target.execute(Target.java:309)
       [ejbdoclet] at org.apache.tools.ant.Target.performTasks(Target.java:336)
       [ejbdoclet] at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
       [ejbdoclet] at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
       [ejbdoclet] at org.eclipse.ant.internal.core.ant.InternalAntRunner.run(InternalAntRunner.java:569)
       [ejbdoclet] at org.eclipse.ant.internal.core.ant.InternalAntRunner.run(InternalAntRunner.java:367)
       [ejbdoclet] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       [ejbdoclet] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       [ejbdoclet] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       [ejbdoclet] at java.lang.reflect.Method.invoke(Method.java:324)
       [ejbdoclet] at org.eclipse.ant.core.AntRunner.run(AntRunner.java:335)
       [ejbdoclet] at org.eclipse.ui.externaltools.internal.ant.launchConfigurations.AntLaunchDelegate.launch(AntLaunchDelegate.java:189)
       [ejbdoclet] at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:156)
       [ejbdoclet] at org.jboss.ide.eclipse.xdoclet.run.ui.actions.XDocletRunAction$1.run(XDocletRunAction.java:142)
       [ejbdoclet] at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:101)
       [ejbdoclet] Caused by: xdoclet.XDocletException: Unknown jboss version number for cmp2 2.4
       [ejbdoclet] at xdoclet.modules.jboss.ejb.JBossSubTask.execute(JBossSubTask.java:542)
       [ejbdoclet] at xdoclet.XDocletMain.start(XDocletMain.java:48)
       [ejbdoclet] at xdoclet.DocletTask.start(DocletTask.java:458)
       [ejbdoclet] ... 18 more
       [ejbdoclet] --- Nested Exception ---
       [ejbdoclet] xdoclet.XDocletException: Unknown jboss version number for cmp2 2.4
       [ejbdoclet] at xdoclet.modules.jboss.ejb.JBossSubTask.execute(JBossSubTask.java:542)
       [ejbdoclet] at xdoclet.XDocletMain.start(XDocletMain.java:48)
       [ejbdoclet] at xdoclet.DocletTask.start(DocletTask.java:458)
       [ejbdoclet] at xjavadoc.ant.XJavadocTask.execute(XJavadocTask.java:95)
      ...


      Carl

        • 1. Re: XDoclet CMP2 Exception
          normanfung

          Have you resolved the problem yet? I'm stuck!

          • 2. Re: XDoclet CMP2 Exception
            manojpn

            I think I got this error when I was trying to publish to JBoss 4.0 server from Eclipse using the JBoss IDE. The issue is that JBoss IDE
            uses the XDoclet 1.2.1 and it does not support JBoss 4.0 server. JBoss 4.0 support is in XDoclet 1.2.2rc1.
            Go here http://sourceforge.net/project/showfiles.php?group_id=31602 and download the 1.2.2rc1 binary file and extract on local drive.
            Go to <ECLIPSE_HOME>\plugins\org.jboss.ide.eclipse.xdoclet.core_1.3.30 and delete all jar files that start with xdoclet (xdoclet*.jar).
            Copy all jar files from xdoclet-1.2.2-RC1\lib (the new dir where you extracted the xdoclet 1.2.2rc1 zip)
            to <ECLIPSE_HOME>\plugins\org.jboss.ide.eclipse.xdoclet.core_1.3.30, overwrite all existing jar files when you copy.
            Start Eclipse and your CMP deployment should work now. You might need to change the xdoclet attributes to point to Ver 4.0 for JBoss server.

            • 3. Re: XDoclet CMP2 Exception

              Ya i also go this error when i tried to use jboss version no as 4.0,when i mobed to 3.0 it worked fine