6 Replies Latest reply on May 12, 2009 9:33 AM by tashtego

    Packaging Persistence Units

    tashtego

       


      http://docs.jboss.org/ejb3/app-server/tutorial/ear/ear.html

      Packaging Persistence Units
      JBoss will not support the Java EE 5 EAR format until version JBoss 5.x. To deploy a persistence archive (a .jar with no EJBs and just persistence units), you must list it in application.xml as an ejb module.


      I am acording to the documentation above and the following (really short) topic:
      http://www.jboss.org/index.html?module=bb&op=viewtopic&t=155228

      Now my question is:
      Is there any workaround to use this solution in JBoss 4, because JBoss 4 is needed for ESB :(

        • 1. Re: Packaging Persistence Units
          jaikiran

          Posting some info from that thread here:

          "Tashtego" wrote:
          What I have done, is:

          Create an EAR project (using Eclipse)
          Create a EJB project
          Create some simple Java project

          The EJB project (later packed as ejbModule.jar) contains one annotated entity.

          The simple Java project containts only META-INF/persistence.xml and is packed as persistence.jar. In this persistence.xml I use the <jar-file> tag to add ejbModule.jar.

          The EAR project containst of course the META-INF/application.xml which includes the persistence.jar as EJB Module. And of course another module called ejbModule.

          Thats how the persistence is separated from the bean. Deploying this under JBoss 5 works, JBoss 4 fails


          Please post the configuration files and also post the entire exception stacktrace which shows the failure. Which exact version of JBossAS do you use?

          While posting logs or xml content or code, please remember to wrap it in a code block by using the Code button in the message editor window. Please use the Preview button to ensure that your post is correctly formatted.

          • 2. Re: Packaging Persistence Units
            tashtego

            Thanks for you answer. The source code follows. The persistence.xml is inside myappPersistence.jar, the person entity inside myappEJB.jar. The tabels are being created in JBoss 5.0.1GA, but not in JBoss 4.2.3GA.

            application.xml:

            <?xml version="1.0" encoding="UTF-8"?>
            <application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
             xmlns="http://java.sun.com/xml/ns/javaee"
             xmlns:application="http://java.sun.com/xml/ns/javae/application_5.xsd"
             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
             http://java.sun.com/xml/ns/javaee/application_5.xsd"
             id="Application_ID" version="5">
             <display-name>myapp</display-name>
             <module>
             <java>myappClient.jar</java>
             </module>
             <module>
             <ejb>myappEJB.jar</ejb>
             </module>
             <module>
             <ejb>myappPersistence.jar</ejb>
             </module>
            </application>
            


            persistence.xml:
            <?xml version="1.0" encoding="UTF-8"?>
            <persistence version="1.0" xmlns="http://java.sun.com/xml/ns/persistence"
             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
             http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">
             <persistence-unit name="myapp" transaction-type="JTA">
             <jta-data-source>java:/myappdb</jta-data-source>
             <jar-file>myappEJB.jar</jar-file>
             <properties>
             <property name="hibernate.dialect" value="org.hibernate.dialect.PostgreSQLDialect"/>
             <property name="hibernate.hbm2ddl.auto" value="update"/>
             </properties>
             </persistence-unit>
            </persistence>
            


            myapp-ds.xml:
            <?xml version="1.0" encoding="UTF-8"?>
            
            <!-- ===================================================================== -->
            <!-- -->
            <!-- JBoss Server Configuration -->
            <!-- -->
            <!-- ===================================================================== -->
            
            <!-- $Id: postgres-ds.xml 63175 2007-05-21 16:26:06Z rrajesh $ -->
            <!-- ==================================================================== -->
            <!-- Datasource config for Postgres -->
            <!-- ==================================================================== -->
            
            
            <datasources>
             <local-tx-datasource>
             <jndi-name>myappdb</jndi-name>
             <connection-url>jdbc:postgresql://localhost:5432/myapp</connection-url>
             <driver-class>org.postgresql.Driver</driver-class>
             <user-name>postgres</user-name>
             <password>postgres</password>
             <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml -->
             <metadata>
             <type-mapping>PostgreSQL</type-mapping>
             </metadata>
             </local-tx-datasource>
            </datasources>
            


            Entity person:
            package de.myapp;
            
            import java.util.UUID;
            
            import javax.persistence.Entity;
            import javax.persistence.Id;
            
            @Entity
            public class Person {
            
             @Id
             private UUID id;
             private String name;
            
             public UUID getId() {
             return id;
             }
            
             public void setId(UUID id) {
             this.id = id;
             }
            
             public String getName() {
             return name;
             }
            
             public void setName(String name) {
             this.name = name;
             }
            
            }
            


            Logfile JBoss 5.0.1GA:
            12:44:12,281 INFO [SessionFactoryObjectFactory] Bound factory to JNDI name: persistence.unit:unitName=myapp.ear/myappPersistence.jar#myapp
            12:44:12,281 WARN [SessionFactoryObjectFactory] InitialContext did not implement EventContext
            12:44:12,281 INFO [SchemaUpdate] Running hbm2ddl schema update
            12:44:12,281 INFO [SchemaUpdate] fetching database metadata
            12:44:12,296 INFO [SchemaUpdate] updating schema
            12:44:12,296 INFO [DatabaseMetadata] table not found: Person
            12:44:12,296 INFO [DatabaseMetadata] table not found: Person
            12:44:12,453 INFO [SchemaUpdate] schema update complete
            12:44:12,453 INFO [NamingHelper] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
            12:44:12,500 INFO [Http11Protocol] Starting Coyote HTTP/1.1 on http-127.0.0.1-8080
            12:44:12,515 INFO [AjpProtocol] Starting Coyote AJP/1.3 on ajp-127.0.0.1-8009
            12:44:12,531 INFO [ServerImpl] JBoss (Microcontainer) [5.0.1.GA (build: SVNTag=JBoss_5_0_1_GA date=200902231221)] Started in 32s:828ms
            


            Logfile JBoss 4.2.3GA:
            12:46:52,890 INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=DataSourceBinding,name=myappdb' to JNDI name 'java:myappdb'
            12:46:52,953 INFO [TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=.../deploy/jmx-console.war/
            12:46:53,015 INFO [EARDeployer] Init J2EE application: file:/C:/Programme/jboss-4.2.3.GA/server/default/deploy/myapp.ear
            12:46:53,109 INFO [JmxKernelAbstraction] creating wrapper delegate for: org.jboss.ejb3.entity.PersistenceUnitDeployment
            12:46:53,109 INFO [JmxKernelAbstraction] installing MBean: persistence.units:ear=myapp.ear,unitName=myapp with dependencies:
            12:46:53,109 INFO [JmxKernelAbstraction] jboss.jca:name=myappdb,service=DataSourceBinding
            12:46:53,109 INFO [PersistenceUnitDeployment] Starting persistence unit persistence.units:ear=myapp.ear,unitName=myapp
            12:46:53,125 INFO [Version] Hibernate EntityManager 3.2.1.GA
            12:46:53,140 INFO [Version] Hibernate Annotations 3.2.1.GA
            12:46:53,140 INFO [Environment] Hibernate 3.2.4.sp1
            12:46:53,140 INFO [Environment] hibernate.properties not found
            12:46:53,140 INFO [Environment] Bytecode provider name : javassist
            12:46:53,140 INFO [Environment] using JDK 1.4 java.sql.Timestamp handling
            12:46:53,203 WARN [ServiceController] Problem starting service persistence.units:ear=myapp.ear,unitName=myapp
            java.lang.RuntimeException: error trying to scan <jar-file>: file:/C:/Programme/jboss-4.2.3.GA/bin/myappEJB.jar
             at org.hibernate.ejb.Ejb3Configuration.scanForClasses(Ejb3Configuration.java:619)
             at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:338)
             at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:126)
             at org.jboss.ejb3.entity.PersistenceUnitDeployment.start(PersistenceUnitDeployment.java:246)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.ejb3.ServiceDelegateWrapper.startService(ServiceDelegateWrapper.java:103)
             at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
             at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
             at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
             at $Proxy0.start(Unknown Source)
             at org.jboss.system.ServiceController.start(ServiceController.java:417)
             at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
             at $Proxy56.start(Unknown Source)
             at org.jboss.ejb3.JmxKernelAbstraction.install(JmxKernelAbstraction.java:120)
             at org.jboss.ejb3.Ejb3Deployment.startPersistenceUnits(Ejb3Deployment.java:627)
             at org.jboss.ejb3.Ejb3Deployment.start(Ejb3Deployment.java:351)
             at org.jboss.ejb3.Ejb3Module.startService(Ejb3Module.java:91)
             at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
             at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
             at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
             at $Proxy0.start(Unknown Source)
             at org.jboss.system.ServiceController.start(ServiceController.java:417)
             at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
             at $Proxy33.start(Unknown Source)
             at org.jboss.ejb3.EJB3Deployer.start(EJB3Deployer.java:512)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
             at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
             at org.jboss.mx.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:97)
             at org.jboss.system.InterceptorServiceMBeanSupport.invokeNext(InterceptorServiceMBeanSupport.java:238)
             at org.jboss.wsf.container.jboss42.DeployerInterceptor.start(DeployerInterceptor.java:87)
             at org.jboss.deployment.SubDeployerInterceptorSupport$XMBeanInterceptor.start(SubDeployerInterceptorSupport.java:188)
             at org.jboss.deployment.SubDeployerInterceptor.invoke(SubDeployerInterceptor.java:95)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
             at $Proxy34.start(Unknown Source)
             at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025)
             at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1015)
             at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819)
             at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
             at sun.reflect.GeneratedMethodAccessor21.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
             at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
             at $Proxy9.deploy(Unknown Source)
             at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:421)
             at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:634)
             at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:263)
             at org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(AbstractDeploymentScanner.java:336)
             at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
             at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
             at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
             at $Proxy0.start(Unknown Source)
             at org.jboss.system.ServiceController.start(ServiceController.java:417)
             at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
             at $Proxy4.start(Unknown Source)
             at org.jboss.deployment.SARDeployer.start(SARDeployer.java:304)
             at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025)
             at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819)
             at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
             at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:766)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
             at java.lang.reflect.Method.invoke(Unknown Source)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
             at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
             at $Proxy5.deploy(Unknown Source)
             at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:482)
             at org.jboss.system.server.ServerImpl.start(ServerImpl.java:362)
             at org.jboss.Main.boot(Main.java:200)
             at org.jboss.Main$1.run(Main.java:508)
             at java.lang.Thread.run(Unknown Source)
            Caused by: java.lang.RuntimeException: java.io.FileNotFoundException: C:\Programme\jboss-4.2.3.GA\bin\myappEJB.jar (Das System kann die angegebene Datei nicht finden)
             at org.jboss.util.file.JarArchiveBrowser.<init>(JarArchiveBrowser.java:74)
             at org.jboss.util.file.FileProtocolArchiveBrowserFactory.create(FileProtocolArchiveBrowserFactory.java:48)
             at org.jboss.util.file.ArchiveBrowser.getBrowser(ArchiveBrowser.java:57)
             at org.hibernate.ejb.Ejb3Configuration.scanForClasses(Ejb3Configuration.java:610)
             ... 146 more
            Caused by: java.io.FileNotFoundException: C:\Programme\jboss-4.2.3.GA\bin\myappEJB.jar (Das System kann die angegebene Datei nicht finden)
             at java.util.zip.ZipFile.open(Native Method)
             at java.util.zip.ZipFile.<init>(Unknown Source)
             at java.util.jar.JarFile.<init>(Unknown Source)
             at java.util.jar.JarFile.<init>(Unknown Source)
             at org.jboss.util.file.JarArchiveBrowser.<init>(JarArchiveBrowser.java:69)
             ... 149 more
            12:46:53,203 INFO [EJB3Deployer] Deployed: file:/C:/Programme/jboss-4.2.3.GA/server/default/tmp/deploy/tmp3852714116206067065myapp.ear-contents/myappPersistence.jar
            12:46:53,218 INFO [EARDeployer] Started J2EE application: file:/C:/Programme/jboss-4.2.3.GA/server/default/deploy/myapp.ear
            12:46:53,218 ERROR [URLDeploymentScanner] Incomplete Deployment listing:
            
            --- MBeans waiting for other MBeans ---
            ObjectName: persistence.units:ear=myapp.ear,unitName=myapp
             State: FAILED
             Reason: java.lang.RuntimeException: error trying to scan <jar-file>: file:/C:/Programme/jboss-4.2.3.GA/bin/myappEJB.jar
             I Depend On:
             jboss.jca:service=DataSourceBinding,name=myappdb
            
            --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
            ObjectName: persistence.units:ear=myapp.ear,unitName=myapp
             State: FAILED
             Reason: java.lang.RuntimeException: error trying to scan <jar-file>: file:/C:/Programme/jboss-4.2.3.GA/bin/myappEJB.jar
             I Depend On:
             jboss.jca:service=DataSourceBinding,name=myappdb
            
            
            12:46:53,250 INFO [Http11Protocol] Starting Coyote HTTP/1.1 on http-127.0.0.1-8080
            12:46:53,265 INFO [AjpProtocol] Starting Coyote AJP/1.3 on ajp-127.0.0.1-8009
            12:46:53,265 INFO [Server] JBoss (MX MicroKernel) [4.2.3.GA (build: SVNTag=JBoss_4_2_3_GA date=200807181417)] Started in 11s:297ms
            


            • 3. Re: Packaging Persistence Units
              jaikiran

               

              java.lang.RuntimeException: error trying to scan <jar-file>: file:/C:/Programme/jboss-4.2.3.GA/bin/myappEJB.jar


              There was a bug related to this, let me see if i can find it and what the resolution was. It was related to incorrect resolution of the relative path for jar-file


              • 4. Re: Packaging Persistence Units
                tashtego

                seems to be that a workaround could be listing all entity classes via instead of using the <jar-file> tag inside persistence.xml.

                Will Jboss 4 be further supported or will ESB have to upgrade to JBoss 5? What will be the next step? ;)

                • 5. Re: Packaging Persistence Units
                  jaikiran

                  Here's the issue i was talking about https://jira.jboss.org/jira/browse/EJBTHREE-724

                  Try

                  <jar-file>../myappEJB.jar</jar-file>



                  • 6. Re: Packaging Persistence Units
                    tashtego

                    great, works. i could have bet i tried that ;)
                    thank you!!