Re: Minimalistic JPA in GWT 2.1.0.M3

2010-10-06 Thread Jin
Hi Yuri, That does sound painful! I would recommend using an EE container with a proper JPA implementation. I guess the first thing when moving to an EE container is to understand a bit about that platform. you can find out more about glassfish at https://glassfish.dev.java.net/. I've been

Re: Minimalistic JPA in GWT 2.1.0.M3

2010-10-06 Thread Y2i
Thanks for your response Jin! I am going to move to EE container. Haven't decided yet which one, currently I am looking at Spring. I do like the fact that GWT team works closely with SpringRoo team, which is a good sign. I also like how Roo leverages AspectJ to generate a lot of boilerplate

Re: Minimalistic JPA in GWT 2.1.0.M3

2010-10-05 Thread Y2i
Hi Jin, Thank you for your response! I was able to make JPA work in Jetty, but only using resource-local entity manager in Java SE environement. This makes sence because for container-managed entity manager an EE environment is required, and Jetty by itslef does not provide it. My persistence

Re: Minimalistic JPA in GWT 2.1.0.M3

2010-10-04 Thread Y2i
I read through Java Persistence API spec and finally was able to make a resource-local entity manager work. persistence.xml went to WEB-INF/ classes/META-INF. I'd like to able to use a container-managed entity manager through injection, but I'm not sure if it is possible at all using a plain web

Re: Minimalistic JPA in GWT 2.1.0.M3

2010-10-04 Thread Jin
Hi Yuri, I went through similar issues trying to get GWT to work with JPA. I would imagine that Jetty does *not* support JPA - I'm using Glassfish Enterprise Server with my GWT app for JEE / JPA support. Glassfish is open source and commercial support can be purchased if that's needed. I've

Re: Minimalistic JPA in GWT 2.1.0.M3

2010-10-01 Thread lineman78
Does your persistence.xml have the following: persistence-unit name=Domain and using the following in your session bean: @PersistenceContext(unitName=Domain) EntityManager em; On Sep 30, 11:08 pm, Y2i yur...@gmail.com wrote: Thanks for the reply.  I'm doing something wrong because I'm

Re: Minimalistic JPA in GWT 2.1.0.M3

2010-10-01 Thread Y2i
persistence.xml has persistence-unit name=Domain. I tried @PersistenceContext, @PersistenceUnit and Persistence.createEntityManagerFactory() without any result. The problem is it does not matter what I type in persistence.xml, jetty does not see the file. I'm doing something fundamentally wrong,

Minimalistic JPA in GWT 2.1.0.M3

2010-09-30 Thread Y2i
Client's requests go the server through RequestFactoryServlet. My service objects (those annotated with @Service(SomeDomainClass.class) on the client side are being called fine. When a service method explicitly creates an entity and returns it to the client, the request returns without problems.

Re: Minimalistic JPA in GWT 2.1.0.M3

2010-09-30 Thread lineman78
persistence.xml should be located in /war/META-INF On Sep 30, 4:28 pm, Y2i yur...@gmail.com wrote: Client's requests go the server through RequestFactoryServlet. My service objects (those annotated with @Service(SomeDomainClass.class) on the client side are being called fine. When a service

Re: Minimalistic JPA in GWT 2.1.0.M3

2010-09-30 Thread Y2i
Thanks for the reply. I'm doing something wrong because I'm getting the same error even when I place persistence.xml to /war/META-INF. javax.persistence.PersistenceException: No Persistence provider for EntityManager named Domain The exception is thrown in both hosted and stand-alone mode. I'll