This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes GWT and the fly likes GAE JPA Can't get Vogella example to work Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » GWT
Bookmark "GAE JPA Can Watch "GAE JPA Can New topic
Author

GAE JPA Can't get Vogella example to work

Laurence Turpin
Greenhorn

Joined: May 21, 2012
Posts: 19
Hello,

I'm using Windows 7, Eclipse Indigo and GAE 1.6.6
I'm trying to learn how to use Java Persistence API on Google App Engine.
At this moment I'm trying to do the example from the following site vogella

I have the following package structure:

When I run the program it fails with an http error 500 and says javax persistence is a restricted class



Here is the code for the PersistsServlet.java file



Here is the code for EMFService.java


Here is the Todo.java file:


Here is the web.xml file:


This is the persistence.xml


and finally the error trace
Laurence Turpin
Greenhorn

Joined: May 21, 2012
Posts: 19
At last I have managed to get this to work.
I reinstalled a new version of eclipse Juno release.
and the latest version of the gae plugin 4.2
The latest plugin includes a persistence.xml
The difference between the persistence.xml that I was using and this one
is in the <provider> section.

In the new persistence.xml it is:

<provider>
org.datanucleus.api.jpa.PersistenceProviderImpl
</provider>

Anyway all is working now.
 
jQuery in Action, 2nd edition
 
subject: GAE JPA Can't get Vogella example to work
 
Similar Threads
Problem with Ext - GWT and hibernate (without Spring)
Error starting Applikation in Eclipse Developer Mode
getting error when deploying web app in weblogic 10.0
Error when calling EntityManager
Problems connecting to a database