HI,

I have trouble running hiebrnate on OSGi. I use
org.springframework.orm.jpa.LocalContainerEntityMa nagerFactoryBean

to start up hibernate. My setup is that I have the emf in Bundle "core" whereas the entities lie in bundle "domain". I see that spring cannot pickup the persistence.xml from the domain bundle, but maybe I have not enough understanding how OsgiBundleResource works internally, I tried different setups.

If I put persistence.xml in the core bundle (where it shouldn't live) spring picks it up, but hibernate doesnt pick up the classes I defined in persistence.xml, log output goes

Code:
org.hibernate.ejb.Version                                         Hibernate EntityManager 3.5.6-Final 
[2010-10-24 09:41:35.486] region-dm-12                 org.hibernate.ejb.Ejb3Configuration                               Processing PersistenceUnitInfo [
	name: de.eiswind.paris.server
	...]
and I see
Code:
Caused by: org.hibernate.hql.ast.QuerySyntaxException: ValueList is not mapped [FROM ValueList v JOIN FETCH v.values WHERE v.name = :name]
although ValueList is definitively in persistence.xml:

Code:
<class>de.eiswind.paris.domain.ValueList</class>
I export/import the domain package clearly between core and domain bundle, so I do not see why this shoudn't work

Any help would be appreciated.
Thomas