-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Duplicate Import
PostPosted: Thu Nov 17, 2005 7:16 pm 
Beginner
Beginner

Joined: Tue Sep 21, 2004 1:49 pm
Posts: 33
Location: Bogota, Colombia
Hibernate version: 2.1.8

Hi, I got a quick question: Isn't it possible to add 2 classes named the same but from different packages to a SessionFactory?

When I try to add 2 classes named the same (and mapped to the same table) but in different packages to the SessionFactory I get:

Code:
"net.sf.hibernate.MappingException: duplicate Import: ClassA".


Some background: The project I'm working on is in a very advanced stage and there are some processes which are eating up the system resources so, in order to improve things, I'm trying to create a lazy copy of all persistent classes in the project to be used in said processes.

I have implemented in recent projects the patterns "Open Session in View", "Thread Local Session", I made some aspects for TX handling, but in this stage of the project is not an option to change that part of the core. I appreciate any suggestions!

Thanks for your time.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Nov 17, 2005 8:13 pm 
Expert
Expert

Joined: Mon Jul 04, 2005 5:19 pm
Posts: 720
can you run hibernate in debug during the Configuration and sessfionFactory build ? post the output if so.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Nov 17, 2005 8:19 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
disable auto import

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Sat Nov 19, 2005 9:14 am 
Beginner
Beginner

Joined: Tue Sep 21, 2004 1:49 pm
Posts: 33
Location: Bogota, Colombia
Yup, that was it, thanks a lot!


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.