Adam -

Have you tried setting the javaagent without the =properties=persis.... ?
Another option would be build/package time enhancement?

Thanks,
Rick

Adam Hardy-4 wrote:
> 
> I'm using the Eclipse Galileo and WTP to run an embedded instance of
> tomcat in 
> Eclipse and I am trying to run enhancement on my webapp's entities using
> any 
> means possible but am having no luck so far.
> 
> The furthest I get is with the javaagent as a parameter on the tomcat
> launch 
> config. However this fails when I try to specify the persistence.xml file.
> I tried:
> 
> -javaagent:/disk2/java/m2-repo/org/apache/openjpa/openjpa/1.2.2-SNAPSHOT/openjpa-1.2.2-SNAPSHOT.jar=properties=persistence.xml#OpenJpaJdbc
> 
> and I get this:
> 
>   by: java.util.MissingResourceException: persistence.xml#OpenJpaJdbc
>       at
> org.apache.openjpa.lib.conf.ProductDerivations.load(ProductDerivations.java:272)
>       at 
> org.apache.openjpa.lib.conf.Configurations.populateConfiguration(Configurations.java:344)
>       at 
> org.apache.openjpa.enhance.PCEnhancerAgent.registerClassLoadEnhancer(PCEnhancerAgent.java:101)
>       at
> org.apache.openjpa.enhance.PCEnhancerAgent.premain(PCEnhancerAgent.java:82)
>       ... 6 more
> 
> The line works fine when I'm using it as a parameter to run junit tests,
> but not 
> here.
> 
> I can see that Eclipse-Tomcat has put the persistence.xml file deep in its 
> directory structure somewhere, but giving the full path as a parameter
> didn't 
> help anyway, it should be picked up from the classpath, I assume.
> 
> Does anyone have this working?
> 
> Thanks
> Adam
> 
> 

-- 
View this message in context: 
http://n2.nabble.com/Eclipse-WTP-tomcat-plugin-tp4127982p4133887.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.

Reply via email to