| Summary: | Using HbEntityDataStore causes org.hibernate.MappingException: Unknown entity:... | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Modeling] EMF | Reporter: | Flavio Donze <flavio.donze> | ||||
| Component: | Teneo | Assignee: | Martin Taal <mtaal> | ||||
| Status: | RESOLVED FIXED | QA Contact: | |||||
| Severity: | major | ||||||
| Priority: | P3 | ||||||
| Version: | unspecified | ||||||
| Target Milestone: | --- | ||||||
| Hardware: | PC | ||||||
| OS: | Windows XP | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
|
Description
Flavio Donze
Created attachment 183606 [details]
Modified QuickStart.java
Martin, It's actually pointless to attach a test model since the error occurs even with a small model having only one object with only an id attribute.
So I modified the QuickStart.java from org.eclipse.emf.teneo.hibernate.examples.
I only changed the following:
// final HbDataStore hbds = HbHelper.INSTANCE
// .createRegisterDataStore(hbName);
HbEntityDataStore hbds = new HbEntityDataStore();
hbds.setName(hbName);
I also had to add javax.persistence to the dependencies.
Can you reproduce this? I'm using my own hibernate bundle.
Need anything else?
It seems that there is a bug in the Hibernate entity meta model creation. This meta model is only needed for entity manager criteria queries and not even then. Hibernate offers a property to disable this meta model creation effectively working around this issue. I have now set this as the default behavior for the entity data store. To try it out yourselve you need to set the following property: hibernate.ejb.metamodel.generation to the value: disabled The default setting of this property will be in the next build. Committed to cvs and new build published Hi Martin Just tested with the new build. Works! Thanks a lot for the fix |