Thanks Rick,
I did as you said and yes it confirms that for some reason the enhancer is not available. My preferred option was to not have to use the enhancer at all and looking at the docs 5.2.2 I expected that if I deployed on Tomcat 1.6 and put in the OpenEJB plug-in, then the classes would be enhanced at deployment time. Up until now I have been using the subclassing enhancer but it seems to run every time create a new entity manager or persist entities, the problem with that apart from performance is that I constantly face OOM or stack overflow issues. Am I wrong or shouldn't Tomcat 1.6 with the OpenEJB plug-in enabled, negate the need for any runtime enhancement? Chris From: Rick Curtis [mailto:[email protected]] Sent: Tuesday, 15 September 2009 11:15 PM To: [email protected]; [email protected] Subject: Re: Enhancer on tomcat Chris - Yes it looks like the -javaagent did not work. As a starting point to debug this problem, I'd suggest setting openjpa.RuntimeUnenhancedClasses=unsupported in your persistence.xml file to disable the subclassing enhancement. Let us know what you come up with. -Rick On Tue, Sep 15, 2009 at 9:49 AM, C N Davies <[email protected]> wrote: I'm trying to configure the runtime enhancer on Tomcat 1.6, but it always fails. I added to my JAVA_OPTS environment variable -javaagent:/temp/openjpa-1.2.1.jar When my application runs I receive warnings like below, which if I am reading it correctly is telling me that the java agent is not working. 1446 trmPU WARN [http-8080-1] openjpa.Enhance - The field asset in type com. trm.core.DataLoadLine is configured to be lazily loaded, but lazy loading is not available for classes that use fieldaccess when not running the OpenJPA enhance r or when dynamic class redefinition is not available. 1446 trmPU WARN [http-8080-1] openjpa.Enhance - The field dataload in type c om.trm.core.DataLoadLine is configured to be lazily loaded, but lazy loading is not available for classes that use fieldaccess when not running the OpenJPA enha ncer or when dynamic class redefinition is not available. Selected item is 00000123BCB71181 5279 trmPU WARN [http-8080-1] openjpa.Enhance - The field asset in type com. trm.core.DataLoadLine is configured to be lazily loaded, but lazy loading is not available for classes that use fieldaccess when not running the OpenJPA enhance r or when dynamic class redefinition is not available. 5280 trmPU WARN [http-8080-1] openjpa.Enhance - The field dataload in type c om.trm.core.DataLoadLine is configured to be lazily loaded, but lazy loading is not available for classes that use fieldaccess when not running the OpenJPA enha ncer or when dynamic class redefinition is not available. Is my understanding correct? Thanks Chris
