Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] question about composite persistence unit

Hi Geronimo,

It is not clear to me why composite persistence units are helpful to you. The most common use case for composite persistence units is to handle a situation where you have multiple databases (or at least multiple database schemas) and you want to compose entities out of those schemas.

Based on my understanding, you may be more interested in the extension mechanism we provide for persistence units. Here is an example that explains:

http://wiki.eclipse.org/EclipseLink/Examples/JPA/Extensibility

-Tom

On 02/03/2012 6:00 AM, Geronimo Ma. Hernandez wrote:
Hello,

I read the wiki entry about composite persistence unit and I wonder, whether
it is possible to extend the list of classes by member persistence units
without specifying the jar-files.

Situation is this:
In an eclipse rcp app I have several plugins, that provide content for common
navigator framework. So the dynamic content is integrated into the shown tree
of main application.
That app does not know, which plugins are added to extend the app.

I'd like do achieve similar functionality with eclipselink to, which means,
the content for CNF is a mapped entity, that should be handled by an entity
manager.
EntityManager will be created by the application, that does not know, which
plugin was added to be handled. So I do not want to add the jarfiles to the
main persistence unit.

All entities are part of the same database, but are declared in independent
plugins/jarfiles.

So how can I notify the entitymanager (or its factory) about the new added
entities (i.e. from an activator of the loaded content-plugin)?


kind regards

Gero
_______________________________________________
eclipselink-users mailing list
eclipselink-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-users


Back to the top