no - all is working fine if i run the reference jar from console. If deployed in Tomcat the persistence unit can be found. my structure is as follows: war/WEB-INF/lib/ are all referenced libraries among others eclipselink-2.0.2.jar, javax.persistence-2.0.0.jar and "gwzDB.jar". The latter includes META-INF/persistence.xml.
the persistence.xml is: <?xml version="1.0" encoding="UTF-8" ?> <persistence version="2.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_2_0.xsd"> <persistence-unit name="gwzPU" transaction-type="RESOURCE_LOCAL"> <provider>org.eclipse.persistence.jpa.PersistenceProvider</ provider> <class>myPackage.Aclass</class> <class>...</class> <properties> <property name="eclipselink.jdbc.batch-writing" value="JDBC" /> <property name="eclipselink.jdbc.batch-writing.size" value="1000" / > <property name="eclipselink.target-database" value="MySQL" /> <property name="eclipselink.jdbc.native-sql" value="true" /> <property name="javax.persistence.jdbc.url" value="jdbc:mysql:// localhost:3306/gwz?rewriteBatchedStatements=true" /> <property name="javax.persistence.jdbc.password" value="gwz" /> <property name="javax.persistence.jdbc.driver" value="com.mysql.jdbc.Driver" /> <property name="javax.persistence.jdbc.user" value="gwz" /> </properties> </persistence-unit> </persistence> On 22 Mrz., 06:10, Y2i <[email protected]> wrote: > I didn't do anything special, just placed persistence.xml into > ./src/META-INF. > > May be you are missing JPA implementation libraries? I keep them in > ./war/WEB-INF/lib. -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
