users@glassfish.java.net

Re: modularity and jpa

From: <glassfish_at_javadesktop.org>
Date: Thu, 22 Feb 2007 22:04:12 PST

What bothers me with current mechanism is because valid entities are said to be non-entities when persisting, just because they were not declared. This is very limitating and frustrating.
If the API has to do the scan at one moment, why doesn't it test for entities at last moment?

I tried having persistence.xml files defining units of same name in multiple jars (in each module, in fact), but it did not help. That would at least have been a palliative.

Is there a way to declare a persistent unit out of an xml file? Eventually, i can declare all jars of the application (once netbeans is loaded, i can trick to get the jar names of all modules), but i don't think i will be able to write a pu anywhere it could be found. Being able to declare by hand, programmatically, could be a workaround.

Thanks for your answers.
[Message sent by forum member 'pepe' (pepe)]

http://forums.java.net/jive/thread.jspa?messageID=204931