EJB « HBM « JPA Q&A





1. hibernate3 maven plugin:make hbm2java generate hibernate annotations instead of ejb3 annotations    stackoverflow.com

Is there a way of forcing the hbm2java goal of hibernate3 maven plugin to generate java classes with hibernate annotations instead of ejb3 annotations? I really do not need ...

2. Identity issue for EJB3.0 Entity along with Hibernate HBM configuration    coderanch.com

Hello Ranchers, I came across a scenario where I have to user Hibernate hbm files along with Annotated EJB3.0 Entity Beans where I am facing an issue while retrieving entity configured as hbm file. Issue : The identity value of the entity is coming with default '0' value set where actual value of id should be primary key value stored in ...

3. incomplete ejb3 tags generated by hbm2java    forum.hibernate.org

hbm2java generates this output in MyObject.java: @OneToMany(cascade={}, fetch=FetchType.LAZY, mappedBy="xxx")^M ^M public Set getMyCollection() {^M return this.myCollection;^M }^M It should generate: @OneToMany(cascade={}, fetch=FetchType.LAZY, mappedBy="xxx", targetEntity="com.xxx.yyy.ejb.entity.MyOtherObject") Because `targetEntity' is missing, I get this exception when loading the par: 20:04:29,683 INFO [Ejb3Configuration] found EJB3 Entity bean: com.xxx.yyy.ejb.entity.Property 20:04:29,714 WARN [ServiceController] Problem creating service jboss.j2ee:service=EJB3,module=xxx.par org.hibernate.AnnotationException: Collection has neither generic type or OneToMany.targetEntity() defined: com.xxx.yyy.ejb.entity.MyObject.myCollection ...