2 Replies Latest reply on Dec 12, 2008 3:42 PM by James Plessinger

    PersistanceUnit for the ear

    James Plessinger Newbie

      I need to access my PersistanceUnit from the beans in mylogic.jar. I have an ear with the following structure.

      myapp.ear
      |-mylogic.jar
      |-myentities.jar
       |-META-INF/persistence.xml
      |-myweb.war
      


      myentities.jar contains the persistance.xml and does not contained any EJBs. If I add myentities.jar as a module the PersistanceUnit is loaded by JBoss but the beans in mylogic.jar can not find the PersistanceUnit. If I add myentities to /lib it's not loaded at all.

      Any ideas on how to load the persistanceUnit from mylogic.jar would be helpfull.

      JBoss 4.2.1 (All of this is EJB3)
      java 1.5_16