1 Reply Latest reply on Apr 19, 2010 8:39 AM by Andi dssdfs

    EJB dependency : NoClassDefFoundError

    Blaise Gosselin Newbie


      I have an EJB that makes reference to a Class packaged in a commons.jar package.
      I have put this commons package at the root of the ejb-jar file, and I have referenced it in my META-INF/MANIFEST.MF file as :

      Class-Path: commons-1.0.jar

      But when I start JBoss, and that it tries to deploy my EJB, I have a NoClassDefFoundError. If I put my package in the lib directory of my AS, it works.

      How have I got to do ?

      Thanks in advance.
      _____________________ _ _ _

        • 1. Re: EJB dependency : NoClassDefFoundError
          Andi dssdfs Newbie



          I have the same problem.


          In my ear. File is an EJB Project (bla.jar)


          the structure from the bla.jar file is:





                 -- jar1.jar

                 -- jar2.jar

                 -- jar3.jar




          The MANIFEST.MF:


          Manifest-Version: 1.0
          Ant-Version: Apache Ant 1.8.0
          Created-By: 1.6.0_19-b04 (Sun Microsystems Inc.)
          Class-Path: lib/jar1.jar lib/jar2.jar lib/jar3.jar



          When I call a EJB-Method from my Web-App which is also in the ear-file I will get a NoClassDefFoundError

          I am using JBoss 5.1.


          Thanks in advance!