-->
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.  [ 7 posts ] 
Author Message
 Post subject: NonuniqueObjectException
PostPosted: Mon Dec 20, 2004 11:10 am 
Beginner
Beginner

Joined: Tue Oct 26, 2004 4:59 pm
Posts: 23
I am having an issue in my application I don't know how to handle.

It's a web application. On each request before the response is sent security is checked to ensure the user is authorized to see the page. The User class uses lazy initialization on its collections, which are a collection of Groups the user belongs to and a collection of Pages the user can see that are not covered by their Group policies.

The issue I am having only happens if the user goes into the Admin area and attempts to edit themselves. Their user object is now persisted in the session. When the security runs it tries to persist the User object from the HttpSession and I get the exception referenced in the subject line. Even if I do a session.clear() beforehand, I get a "dirty collection reference" error on some actions.

Thanks,
Karl


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 20, 2004 11:21 am 
Beginner
Beginner

Joined: Tue Oct 26, 2004 4:59 pm
Posts: 23
One other thing I tried was doing a session.contains() before persisting the User object in the security. This seemed liked it should work according to the API but it didn't. It would always return false.

Thanks,
Karl


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 21, 2004 10:03 am 
Beginner
Beginner

Joined: Tue Oct 26, 2004 4:59 pm
Posts: 23
Does anyone know of another Hibernate Forum, one where I can expect some feedback on my questions. 75% of my questions here don't even get a response.

Thanks,
Karl


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 21, 2004 1:02 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
well - you don't ask questions that is very answerable....folllow the posting rules (by showing the failing code etc.) and you will get better feedback....

I tend to say the above line 5-10 times every day - but i don't do it on every questions since then i would do it all day ....and that i don't have time for ;)

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 21, 2004 1:03 pm 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
Consider commercial support.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 21, 2004 3:48 pm 
Beginner
Beginner

Joined: Tue Oct 26, 2004 4:59 pm
Posts: 23
I've posted questions with code and mappings before and still gotten no response so that doesn't really help does it.

Karl


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 21, 2004 3:49 pm 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
Complaining also doesn't help. Keep in mind that its your responsibility to fix your code, not ours. This is a free forum. If you need personal attention, buy commercial support.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 7 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.