Hi *, we're trying to use JPA within an OSGi-Application. We decided to use OpenJPA with Derby.
We have a bundle A, which implements an service-interface that offers an EntityManager. The interface-method has no parameters. Another bundle B uses this service to retrieve an EntityManager and to persist class C (which is located in bundle B and which package is just private). So bundle A knows nothing about class C, the EntityManager is created with not knowing about C too. The consequence is that the EntityManager don't persist C because C is not enhanced. We found out that with BuddyPolicy from equinox-framework, things get work. But we don't want to have framework-specific things. Another possibility is using 'DynamicImport-Package: *' in bundle A and to export class C in bundle B - but thats an option, which we consider to be dirty. We played with classloading-mechanism, but those games didn't work. So, how do other people use (Open)JPA within OSGi? Is it maybe better, to switch to Hibernate with database XXX? Yet, there must be a solution for it!? Thanks for reply, Kevin --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

