-->
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.  [ 2 posts ] 
Author Message
 Post subject: Different caches for different contexts?
PostPosted: Thu Mar 04, 2004 5:12 pm 
Regular
Regular

Joined: Fri Aug 29, 2003 12:48 pm
Posts: 63
Hi guys. I'm just now beginning to play with the second-level cache stuff. I can of course see how to configure caching for my objects in their .hbm.xml mapping files, but what is the best practice if I want different cache strategies for different contexts? For example, in my public servlet, I might want some mostly immutable objects to be cached read-only. But in my command-line admin tool, I'd obviously not want a read-only cache.

Is this possible? Is it recommended? (e.g. different SessionFactories, perhaps in separate JVM's, accessing the same data store, perhaps with different caching strategies)


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 04, 2004 7:09 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 12:50 pm
Posts: 5130
Location: Melbourne, Australia
Cache strategy can also be specified in hibernate.cfg.xml, or by programmatically manipulating the Configuration objects.


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