-->
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.  [ 1 post ] 
Author Message
 Post subject: Synchronizing 2 detached objects in a very long conversation
PostPosted: Wed Dec 05, 2007 1:11 pm 
Newbie

Joined: Wed Dec 05, 2007 12:50 pm
Posts: 1
I have a design issue i am not sure about. i have a hibernate object i use in various threads. i am fetching the same object from the database and since it is done in different sessions they are allocated with different JVM ids.

I put both objects (which should reflect the same object in the database) in different sets.

My question is: how do i make sure their data is synchronized?
My application is not very intense so for now i don't care too much about locking but more about data consistency. if i would have worked in the context of the same session the answer would have been very simple. but i am working in a multi threaded environment and the life time of the objects is rather long (up to an hour and maybe more).

Which hibernates' strategy is the best for me?. please advise.

E

_________________
Creative Calls - Personalizing online advertising


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

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.