-->
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.  [ 3 posts ] 
Author Message
 Post subject: Hibernate cache under heavy load
PostPosted: Tue Aug 17, 2004 11:30 pm 
Beginner
Beginner

Joined: Tue Aug 17, 2004 11:27 pm
Posts: 24
We are currently caching all of our hibernate objects and queries using ehcache. We use the Spring OpenSessionInViewFilter to lazily access our objects. The site behaves normally and performs very well under light load, but we experience inconsistant behaviour when we send a lot of requests to application when the cache is empty. Basically many of the initial requests return with data missing . As the cache builds up, the data starts to appear.

I was wondering if anyone else has experienced this same behavior. Is there some kind of synchronization issue I am missing in regards the hibernate cache? Any help would be greatly appreciated. Thanks!

Karl


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 18, 2004 3:11 am 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
Thats the nature of the cache and your statement that you cache "all objects" makes me think that you didn't consider the appropriate caching concurrency strategies. This is extremely difficult to resolve in an online discussion, I recommend you get a copy of Hibernate in Action and read the caching chapter. It contains many guidelines what kinds of data should be cached, with what concurrency strategy.

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 18, 2004 3:32 am 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
I agree the book helps a lot particulary on that subject

_________________
Emmanuel


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