Brett Meyer edited a comment on New Feature HHH-7527

All, I was finally able to get a simple example working on Apache Karaf using container-managed Enterprise OSGi JPA.

Pull request: https://github.com/hibernate/hibernate-orm/pull/465/files

I would really appreciate it if some of you could grab the following fork and try it out in your own environments – feedback is definitely needed:
https://github.com/brmeyer/hibernate-orm/tree/4.2-osgi

A simple test client bundle is available as a reference. Something like this will eventually wind up in the doc examples. Instructions are in the README (rough draft).
https://github.com/brmeyer/HibernateOSGi

There's a few caveats to ORM at this point:
1.) I have not yet tested a bundle creating and maintaining it's own EntityManagerFactory or SessionFactory. Only container-managed has been used so far.
2.) Only basic support for persistence units is available. We have not handled the use of OSGi services to register Integrators, etc.
3.) IMPORTANT: We can currently handle only annotated classes explicitly listed in your persistence unit. There's a few roadblocks preventing us from scanning for mapping files, classes, etc.
4.) The provided feature.xml files are fairly order-specific. Some comments in them need thought through.

The proposal wiki is updated with more info and questions:
https://github.com/hibernate/hibernate-orm/wiki/Proposal:-OSGi

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira