3 Replies Latest reply on Jul 25, 2008 7:00 AM by lynchie

    jar-file in persistence.xml and eclipse directory

    Kamil Demecki Novice


      Hi all !

      I'm trying run junit tests from Eclipse. I have entities in few projects. When I apply jar-file with jar it's ok, but don't work with eclipse directories.

      <?xml version="1.0" encoding="UTF-8"?>
      <persistence 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"
       version="1.0">
       <persistence-unit name="bussinessPU">
       <jta-data-source>java:/bussinessDS</jta-data-source>
      
       <!-- doesnt work -->
       <jar-file>../../../testejb3-bussiness-moduleb-ob/target/classes</jar-file>
      
       <!-- ok -->
       <!-- <jar-file>../moduleb.jar</jar-file> -->
      
       <properties>
       <property name="hibernate.dialect" value="org.hibernate.dialect.PostgreSQLDialect" />
       <property name="hibernate.hbm2ddl.auto" value="create-drop" />
       </properties>
       </persistence-unit>
      </persistence>
      


      Is jar-file scanning also directories ?

      My problem would by resolved too by something like http://jira.springframework.org/browse/SPR-2598 . Nobody answer on this http://www.jboss.com/index.html?module=bb&op=viewtopic&t=96863 since 2006 so there is still impossible ? ;)