-->
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: How to clear NHibernate Cache
PostPosted: Tue Jan 01, 2008 2:25 pm 
Newbie

Joined: Tue Jan 01, 2008 2:21 pm
Posts: 4
Is it possible to clear the NHibernate cache programatically? If I retrieve an object with NHibernate and later change the data in the database manually NHibernate will continue serving the version from the cache whenever the object is retrieved. Is there a way to force it to refresh from the database? The only way I could figure out so far is to restart the host process (e.g. IIS), and the documentation is silent on this topic.

Thanks


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 02, 2008 3:50 am 
Regular
Regular

Joined: Tue Aug 08, 2006 4:28 am
Posts: 96
Location: Hong Kong
Please check documentation section 15.3. Managing the caches
http://www.hibernate.org/hib_docs/nhibernate/1.2/reference/en/html/performance.html#performance-sessioncache


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 02, 2008 10:51 pm 
Newbie

Joined: Tue Jan 01, 2008 2:21 pm
Posts: 4
I don't know how I missed this before. Thanks!


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.