I have two different applications deployed on the same jboss4.0.4.GA server. 
Each application using its own persistence unit. Persistent units declared in 
persistent.xml (<persistence-unit name="app1">, <persistence-unit 
name="app2">). Both applications using ejb3 entity beans with same name. This 
name is very common (Event) and i have no possibility to refactor applications 
and rename beans. Jboss rises exception when applications deployed. Is it 
normal behavior?

  | org.hibernate.AnnotationException: Use of the same entity name twice: Event
  |     at 
org.hibernate.cfg.annotations.EntityBinder.bindEntity(EntityBinder.java:221)
  |     at 
org.hibernate.cfg.AnnotationBinder.bindClass(AnnotationBinder.java:531)
  |     at 
org.hibernate.cfg.AnnotationConfiguration.processArtifactsOfType(AnnotationConfiguration.java:452)
  |     at 
org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(AnnotationConfiguration.java:268)
  |     at 
org.hibernate.cfg.Configuration.buildMappings(Configuration.java:1039)
  |     at 
org.hibernate.ejb.Ejb3Configuration.buildMappings(Ejb3Configuration.java:1211)
  |     at 
org.hibernate.ejb.EventListenerConfigurator.configure(EventListenerConfigurator.java:154)
  |     at 
org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:847)
  |     at 
org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:385)
  | 

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3993035#3993035

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3993035
_______________________________________________
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to