-
Jan 8th, 2009, 09:14 PM
#1
persistence.xml and <jar-file>
I have entities in two separate jars that are loaded by my webapp. The only way I have found to make this work is to have a persistence.xml in my webapp that loads the entities using the jar-file tag. The problem is that the only way I can make it work is to use absolute file URLs to the jars, which is not workable for production. Can someone please tell me the right incantation for a relative URL? I've tried everything I can think of.
Also, is there a more elegant way than using jar-file?
(I'm posting here because I'm using a Spring 2.5 / EJB3 infrastructure, i.e. the annotations Repository, Service, PersistenceContext, Resource.)
Any help is appreciated.
Thanks,
Julian
-
May 5th, 2009, 09:50 AM
#2
I am finding the same problem right now... after extracting out my jpa domain into a seperate jar which will be used in multiple projects. Anyone have any ideas on this?
-
May 5th, 2009, 11:22 AM
#3
We ended up solving the problem by implementing PersistenceUnitPostProcessor. See my post at:
http://javathoughts.capesugarbird.co...nce-units.html
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules