0 Replies Latest reply on Feb 19, 2007 3:32 PM by pbzdyl

    EJB3 deployment and ClassDefNotFound

    pbzdyl

      Hello All,

      I have following ear application structure:

      sample-app.ear
      
       META-INF
       application.xml (cited in the end of this post)
       MANIFEST.MF (containing: Class-Path: sample-logic-api.jar sample-model.jar sample-logic-.jar
      
       sample-model.jar
       net.bzdyl.sample.model.Customer (simple entity with @Entity)
      
       sample-logic-api.jar
       net.bzdyl.sample.logic.CustomerManager (simple interface with create/update/delete/query methods, no annotations)
      
       sample-logic-impl.jar
       META-INF
       persistence.xml (cited in the end of this post)
       MANIFEST.MF (containig: Class-Path: sample-logic-api-.jar sample-model.jar
       net.bzdyl.sample.logic.CustomerManagerBean (with @Remote(CustomerManager.class) @Stateless annotations)
      


      When I am deploying it on JBoss 4.0.5.GA (with EARDeployer configured with Isolated=true) it is working fine. But when I am installing it on JBoss 5.0.0.Beta1 (default configuration) I am getting

      21:24:37,891 ERROR [EJBRegistrationDeployer] Error during deployment: jar:file:/
      C:/dev/java/jboss-5.0.0.Beta1/server/default/deploy/sample-app.ear!/
      sample-logic-impl.jar
      java.lang.NoClassDefFoundError: net/bzdyl/sample/logic/CustomerManager

      during deployment process. Why?

      Thanks,
      Piotrek

      application.xml

      <?xml version="1.0" encoding="UTF-8"?>
      <application xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd" version="5">
       <description>Sample application</description>
       <display-name>sample-ear</display-name>
       <module>
       <ejb>sample-logic-impl-.jar</ejb>
       </module>
      </application>
      


      persistence.xml

      <persistence>
       <persistence-unit name="SamplePU">
       <jta-data-source>java:/DefaultDS</jta-data-source>
       <properties>
       <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
       <property name="hibernate.show_sql" value="true"/>
       </properties>
       <class>net.bzdyl.sample.model.Customer</class>
       </persistence-unit>
      </persistence>