users@glassfish.java.net

Re: GF3 + OpenJPA 2.0 - Enhancer not working

From: <glassfish_at_javadesktop.org>
Date: Tue, 20 Jul 2010 04:34:21 PDT

Hello Mitesh,

thanks for your support.

---- Mitesh Meswani ---

This seems to indicate that you are using JavaSE style (that is calling
Persistence.createEMF() ) to instantiate your EMF. Here the container
does not get chance to communicate with Open JPA to install the
necessary hooks to enable enhancements. You will need to fall back to
statically enhance as you are doing currently with this mode.

---- /Mitesh Meswani ---

The weird thing is, that it is working this way using WebSphere. Anyway, I'll try using dependency injection now (I had some trouble using it while relying on hibernate ... that's why I'm going this way).

---- Mitesh Meswani ---

Just copying all the libs required by OpenJPA to the lib dir should
work. What issue do you get when you do this?

---- /Mitesh Meswani ---

I can just copy it, but the enhancer didnt work (it said, no enhanced entity classes were found and therefore it didnt work - which is not the correct statement; I dont have it here right now, will try to get it for you - ).

Thanks.

Stefan
[Message sent by forum member 'kniffte']

http://forums.java.net/jive/thread.jspa?messageID=478069