How is it recommended (or even possible) to handle the case when a product is using thirdparty jars which include @Entity's where the names conflict, and it is not possible to change the source code to fix the conflict?
For example,
ComponentA.jar:
Code:
package com.componentA.foo;
@Entity
public class Order { ...}
ComponentB.jar:
Code:
package com.componentB.bar;
@Entity
public class Order { ...}
When hibernate loads these classes it will use only the unqualified name of the class ("Order") and hence result in error. (See
http://opensource.atlassian.com/project ... se/ANN-341).
Has anybody run into this? How do you work around it? I can't find anything in the spec which states the the default for @Entity.name() /must/ be the unqualified name of the class. In fact, I can't find anything at all on how to handle @Entity name conflicts.
thanks!!
Hibernate version:
3.1.2