Comment by [email protected]:

It looks that injecting EntityManager this way:

@Inject
EntityManager em;

breaks persist() and merge() functionality. I tested it on Jboss 5/Hibernate. Everyting else works, but objects just won't be saved. We had to change it to:

@Inject
Provider<EntityManager> em;


There are great warp-persist examples here: http://code.google.com/p/warp-persist-sample/. With minor modifications it will work with guice-persist engine.

For more information:
http://code.google.com/p/google-guice/wiki/JPA

--
You received this message because you are subscribed to the Google Groups 
"google-guice-dev" 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-guice-dev?hl=en.

Reply via email to