openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Prodoc <...@hobba.nl>
Subject Re: Enhancing entities: getting desperate
Date Tue, 19 May 2009 14:09:43 GMT

Darn, I shouted too soon...
I just performed a clean and with the same build config as mentioned in my
last post I now get presented with a different error:

java.lang.IllegalArgumentException: java.lang.ClassNotFoundException:
mpsf.entities.EngagementRange

It appears to have worked before because I did a compile without the
enhancer. I just don't understand why getting enhancement to work is so
troublesome. I suspect that I'll be prented with the error in the previous
e-mail again as soon as I manage to fix this one.



Prodoc wrote:
> 
> 
> 
> Michael Dick wrote:
>> 
>> Do you have all your entities listed in persistence.xml? The exceptions
>> below look like the list is either missing, or doesn't have a complete
>> list
>> of your entities.
>> 
> 
> Thanks for your reply Michael. Yes, I do have all the entities included in
> persistence.xml except for all the embeddables.
> 
> After further investigation I found that the enhance target was never
> processed because I didn't know I had to call it from elsewhere in the
> build files *hits head against desk*. I now get the enhancer to run but I
> had to deal with serveral issues afterwards ('MetaDataFactory could not be
> configured', 'java.lang.ClassNotFoundException', etc.). I feel that I'm
> slowly getting closer to get it to start enhancing but I'm stuck with one
> more problem.
> 
> The build.xml file now contains the following:
> 
> -------------------------------------------------------------------------------------------------

>    <path id="jpa.enhancement.classpath"> 
>       <pathelement location="build/classes"/> 
>       
>       <fileset dir="lib/apache-openjpa-1.2.1"> 
>          <include name="**/*.jar"/> 
>       </fileset> 
>    </path>
>  
>    <target name="enhance">
>       <taskdef name="openjpac"
> classname="org.apache.openjpa.ant.PCEnhancerTask"> 
>          <classpath refid="jpa.enhancement.classpath"/> 
>       </taskdef> 
> 
>       <openjpac>
>          <config propertiesFile="./src/META-INF/persistence.xml"/>
> 
>          <fileset dir=".">
>             <include name="**/src/mpsf/entities/*.java">
>          </fileset>
> 
>          <classpath refid="jpa.enhancement.classpath"/> 
>       </openjpac> 
>    </target> 
> -------------------------------------------------------------------------------------------------

> 
> The error I'm now presented with is:
> 
> -------------------------------------------------------------------------------------------------

> enhance:
> java.lang.NoClassDefFoundError: org/w3c/dom/svg/SVGDocument
>     at java.lang.Class.getDeclaredMethods0(Native Method)
>     at java.lang.Class.privateGetDeclaredMethods(Class.java:2427)
>     at java.lang.Class.getDeclaredMethods(Class.java:1791)
>     at
> org.apache.openjpa.lib.util.J2DoPrivHelper$9.run(J2DoPrivHelper.java:305)
>     ...
> -------------------------------------------------------------------------------------------------

> 
> Any idea what this could be?
> 
> Yours,
> 
> Age
> 
> 

-- 
View this message in context: http://n2.nabble.com/Enhancing-entities%3A-getting-desperate-tp2937944p2939749.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.


Mime
View raw message