Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » Configure Hibernate as JPA Provider
Configure Hibernate as JPA Provider [message #691550] Fri, 01 July 2011 13:39
Odili Charles Opute is currently offline Odili Charles Opute
Messages: 1
Registered: July 2011
Junior Member
I have a working Helios installation on which I have set up GWT 2.3 on. I am using Hibernate 3.6 as my JPA provider in a GWT project however when I deploy to my Glassfish server and try to use features in the app, I get errors complaining about EclipseLink which I not even using in my project.

Here is my persistence.xml file contents:
<?xml version="1.0" encoding="UTF-8"?>
<persistence ....>
	<persistence-unit name="Thriftr" transaction-type="RESOURCE_LOCAL">
		<class>com.bitrunk.apps.thriftr.server.model.ClientType</class>
	    <class>com.bitrunk.apps.thriftr.server.model.Department</class>
	    <class>com.bitrunk.apps.thriftr.server.model.Faculty</class>
	    <class>com.bitrunk.apps.thriftr.server.model.Gender</class>
	    <class>com.bitrunk.apps.thriftr.server.model.Loan</class>
	    <class>com.bitrunk.apps.thriftr.server.model.LoanApplyType</class>
	    <class>com.bitrunk.apps.thriftr.server.model.LoanCategory</class>
	    <class>com.bitrunk.apps.thriftr.server.model.LoanSettlement</class>
	    <class>com.bitrunk.apps.thriftr.server.model.LoanType</class>
	    <class>com.bitrunk.apps.thriftr.server.model.SsaClient</class>
	    <class>com.bitrunk.apps.thriftr.server.model.User</class>
	    <class>com.bitrunk.apps.thriftr.server.model.DeductionEntry</class>
	    <class>com.bitrunk.apps.thriftr.server.model.SettlementStatus</class>
	    <class>com.bitrunk.apps.thriftr.server.model.DeductionSummary</class>
	    <class>com.bitrunk.apps.thriftr.server.model.VariationEntry</class>
	    <class>com.bitrunk.apps.thriftr.server.model.VariationSummary</class>
	    <class>com.bitrunk.apps.thriftr.server.model.LoanTenure</class>
	    <class>com.bitrunk.apps.thriftr.server.model.ImportItem</class>
		
		<exclude-unlisted-classes>true</exclude-unlisted-classes>
		<properties>
			<property name="javax.persistence.jdbc.url" value="jdbc:mysql://localhost:3306/thriftrdb"/>
			<property name="javax.persistence.jdbc.user" value="root"/>
			<property name="javax.persistence.jdbc.driver" value="com.mysql.jdbc.Driver"/>
			<property name="javax.persistence.jdbc.password" value="asAdm1n"/>
		</properties>
	</persistence-unit>
</persistence>


And here is my hibernate.cfg.xml file contents :
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE ...>
<hibernate-configuration>
  <session-factory>
    <property name="hibernate.dialect">org.hibernate.dialect.MySQLDialect</property>
    <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
    <property name="hibernate.connection.url">jdbc:mysql://localhost:3306/thriftrdb</property>
    <property name="hibernate.connection.username">root</property>
    <property name="hibernate.connection.password">asAdm1n</property>
  </session-factory>
</hibernate-configuration>


As you can see I am using Hibernate and not EclipseLink, secondly every works in GWT dev-mode until I deploy the app. Please is there something I am missing ??
Previous Topic:JDT - custom xml language - integration
Next Topic:Javadoc not displaying in template proposal
Goto Forum:
  


Current Time: Tue Jul 22 15:53:58 EDT 2014

Powered by FUDForum. Page generated in 0.06503 seconds