2 Replies Latest reply on Sep 21, 2009 11:18 AM by Walter Diego Luque

    ClassNotFoundException Moving Persistence.xml From EJB/META-

    Walter Diego Luque Newbie

      Hi, i have a application with the next structure (work fine un jboss 4.2.2.ga) :

      ..FMK-EAR
      ......fmk-war
      ......fmk-seam ( Seam Actions Ejb )
      ......fmk-sessionEjb ( Ejb beans )
      ......fmk-zentities ( Ejb with the entities definition )
      ......META-INF
      ............application.xml
      ............jboss-app.xml
      ............persistence.xml ( move recently )

      In fmksessionEjb i have @PersistenceContext(unitName = "ejb3FMK") , so I move the persistence.xml from fmk-zentities/META-INF to FMK-EAR/META-INF.

      I read in some post, that this is necessary for persistence unit is visible to fmk-sessionEjb.

      Now i have the next error :

      javax.persistence.PersistenceException: [PersistenceUnit: ejb3FMK] class or package not found
      ....
      Caused by: java.lang.ClassNotFoundException: fmk-zentities.jar.com.multiSistemas.fmk.entity.security.UserSecuritySpaceAccess from ...

      The class com.multiSistemas.fmk.entity.security.UserSecuritySpace exists in fmk-zentities.jar .

      What is wrong? any idea?

      Thank in advance