-
1. Re: entity bean name in ejb3 RC7
mzeijen Aug 23, 2006 6:03 PM (in response to michalzel)I am having the same problem. Somehow Hibernate can't find the entitity classes in a different ejb package within the same ear package. I would really like to now how to fix this.
-
2. Re: entity bean name in ejb3 RC7
michalzel Aug 24, 2006 3:04 AM (in response to michalzel)I found something, which I unfortunatelly don't have to time to check right now. There should be line:
... <jta-data-source>java:/UMKDS</jta-data-source> <jar-file>../data.jar</jar-file> <properties> ...
at persistence.xml, where data.jar is jar with entities. If you check it, I will appreciate if you could tell If it works.
regards
Michal -
3. Re: entity bean name in ejb3 RC7
mzeijen Aug 24, 2006 4:11 AM (in response to michalzel)OK, I'll check it today.
-
4. Re: entity bean name in ejb3 RC7
mzeijen Aug 24, 2006 6:56 AM (in response to michalzel)I've tried it and it should work but it doesn't :( . There is a bug that incorrectly generates the wrong path to the jar file. I hope they fix this soon.
I do however have a workaround. You can use the class property to list all the persistence classes that you want to have available in the persistence manager.
Example:... <jta-data-source>java:/MyDS</jta-data-source> <class>yPackage.User</class> <class>yPackage.SomeOtherEntity</class> <properties> ...
It isn't really nice, but it works. I tested it. -
5. Re: entity bean name in ejb3 RC7
ikkida Sep 4, 2006 9:15 AM (in response to michalzel)Hi,
I am developing a seam application integrated with JBPM. I am using Seam 1.0.1.GA on Jboss 4.0.4.GA with JBPM 3.1 I have a combined persistnace for JBMP and my application objects.
When I do a create query as follows:
User found =
(User) em.createQuery("from JBPM_ID_USER u where u.ID__ = :userName and u.PASSWORD_ = :password")
.setParameter("userName", username)
.setParameter("password", password)
.getSingleResult();
I get the following error:
15:08:26,080 ERROR [STDERR] javax.persistence.PersistenceException: org.hibernat
e.hql.ast.QuerySyntaxException: JBPM_ID_USER is not mapped [select NAME_ from JBPM_ID_USER]
I have copied the jbpm-identity-3.1.jar into ejb3 folder for the ear
have the following entires in the hibernate.cfg.xml
mapping resource="org/jbpm/identity/User.hbm.xml"
mapping resource="org/jbpm/identity/Group.hbm.xml"
mapping resource="org/jbpm/identity/Membership.hbm.xml"
I hve tried both the ways mentioned above,but both ways failed to solve the issue.
Can anybody throw some light on this.
Thanks,
Ikram