Search in sources :

Example 31 with EnterpriseBeanInfo

use of org.apache.openejb.assembler.classic.EnterpriseBeanInfo in project aries by apache.

the class EJBExtender method processJPAMappings.

private void processJPAMappings(EjbJarInfo ejbInfo) {
    for (EnterpriseBeanInfo ebi : ejbInfo.enterpriseBeans) {
        for (PersistenceUnitReferenceInfo pui : ebi.jndiEnc.persistenceUnitRefs) {
            pui.location = new ReferenceLocationInfo();
            pui.location.jndiName = "aries/integration/unit/" + pui.persistenceUnitName;
        }
        for (PersistenceContextReferenceInfo pci : ebi.jndiEnc.persistenceContextRefs) {
            pci.location = new ReferenceLocationInfo();
            pci.location.jndiName = "aries/integration/context/" + pci.persistenceUnitName;
        }
    }
}
Also used : EnterpriseBeanInfo(org.apache.openejb.assembler.classic.EnterpriseBeanInfo) PersistenceContextReferenceInfo(org.apache.openejb.assembler.classic.PersistenceContextReferenceInfo) ReferenceLocationInfo(org.apache.openejb.assembler.classic.ReferenceLocationInfo) PersistenceUnitReferenceInfo(org.apache.openejb.assembler.classic.PersistenceUnitReferenceInfo)

Aggregations

EnterpriseBeanInfo (org.apache.openejb.assembler.classic.EnterpriseBeanInfo)31 EjbJarInfo (org.apache.openejb.assembler.classic.EjbJarInfo)17 BeanContext (org.apache.openejb.BeanContext)8 HashMap (java.util.HashMap)7 AppInfo (org.apache.openejb.assembler.classic.AppInfo)7 WebAppInfo (org.apache.openejb.assembler.classic.WebAppInfo)7 Assembler (org.apache.openejb.assembler.classic.Assembler)6 EjbJar (org.apache.openejb.jee.EjbJar)6 ArrayList (java.util.ArrayList)5 OpenEJBException (org.apache.openejb.OpenEJBException)5 StatelessBean (org.apache.openejb.jee.StatelessBean)5 SecurityServiceInfo (org.apache.openejb.assembler.classic.SecurityServiceInfo)4 SingletonBeanInfo (org.apache.openejb.assembler.classic.SingletonBeanInfo)4 TransactionServiceInfo (org.apache.openejb.assembler.classic.TransactionServiceInfo)4 EjbDeployment (org.apache.openejb.jee.oejb3.EjbDeployment)4 URL (java.net.URL)3 Map (java.util.Map)3 InitialContext (javax.naming.InitialContext)3 StatelessBeanInfo (org.apache.openejb.assembler.classic.StatelessBeanInfo)3 File (java.io.File)2