openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel Dyer" <>
Subject openjpac Ant task
Date Thu, 13 Dec 2007 22:34:29 GMT
I've been using the runtime agent approach for enhancing my classes and  
now I would like to switch to build-time enhancement.

I'd appreciate it if somebody could help me understand exactly what is  

What I would like to know is what does the openjpac Ant task need the  
persistence.xml for?  Is enhancement specific to the particular database  
that I am using?  There is apparently no other information in there that  
could be useful (I already specify which classes to look at by providing a  
fileset to the Ant task).

My problem is that when I add the persistence.xml to the Ant task, it  
fails because I have specified the <jar-file> element and the JAR file it  
references does not exist yet (how can it? I have to enhance the classes  
before packaging them in a JAR).  If I don't provide the persistence.xml  
it fails because "MetaDataFactory could not be configured".  I suppose I  
could create a different persistence.xml just for this step, but is it  

Also, currently (with the runtime agent enhancement) I am using the same  
entity classes with 2 different databases (I use H2 for the unit tests and  
MySQL for the actual application).  If enhancement is database specific, I  
guess I can't do this with build-time enhancement (I would need 2 versions  
of the enhanced classes).

Thanks for any insights you can give me,


Daniel Dyer

View raw message