3 Replies Latest reply on Jan 31, 2007 1:24 PM by James Brown

    JBoss 4.0.4GA and JAXB

    tdevos Newbie

      Hi everyone,

      I started the problem on the installation and deployment forum but I was asked to move to this forum.

      I try to upgrade our JBoss 4.0.3SP1 to JBoss 4.0.4GA. In our application we make use of JAXB. In JBoss 4.0.3SP1 I added the JAXB JWSDP 1.6 libraries to the default/deploy/lib directory and everything worked fine.

      However, if I follow the same procedure for JBoss 4.0.4GA (putting the JAXB JWSDP 1.6 libraries in default/lib) I got the following exception when deploying the EAR file.

      java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException.

      Further investigation shows that this class is defined in 2 jars. jboss-j2ee.jar (source JBoss) and jaxb-api.jar (source JWSDP 1.6). However then if I delete the jaxb-api.jar it fails with classes he can`t find which is normal since they are not in the JBoss distribution.

      I found at the wiki that JWSDP is not supported anymore in JBoss 4.0.4GA but I need to use JAXB and this is not available in JBossWS as far as I know.

      I tried to experiment further reading the wiki`s about the classloading issues but unfortunatly wihtout any result. (Enabled isolation and Java2ParentDelegation). I don`t understand why JBoss uses an own implementation of the javax.xml.bind package. Am I right that the the javax.* and java.* packages are always loaded through the default class loader. Maybe this explains, however doesn`t solve the problem.

      Am I right that in JBoss 4.0.3SP1 the JWSDP libraries where compatible but not for JBoss 4.0.4? Is it usefull to update to jwsdp 2.0? However, this contains an early access release of JAXB 2.0 and maybe this is not recommended for a production environment.


      Tim De Vos