HighTechTalks DotNet Forums  

asp cache flush nearly all

ASP.net Caching microsoft.public.dotnet.framework.aspnet.caching


Discuss asp cache flush nearly all in the ASP.net Caching forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Dicky Cheng
 
Posts: n/a

Default asp cache flush nearly all - 11-25-2004 , 01:20 AM






Hi,
I am using HttpRuntime.Cache.Insert(key, object) to cache some object in my
web application. I am using IIS 6 and /3GB option to support my 3Gb physical
memory. I've set the maximum used memory to 1800Mb in the application pool.
When my web app cache object increase and the private byte nearly 1.5Gb, the
cache will start flush from 15000 entries to 800 entries and the private
byte become 300Mb now. Can I control the flushing amount (i don't want to
flush nearly all cache objects)? and it is not what I expected that the app
will nearly 1.8G to start flushing (there still 300M to go).
Thanks in advance,
Dicky Cheng



Reply With Quote
  #2  
Old   
Ben Strackany
 
Posts: n/a

Default Re: asp cache flush nearly all - 11-29-2004 , 02:22 PM






Well, you could set the priority of the objects that you cache. In theory
the lower-priority items will be released before high-priority ones.

Otherwise, if your pool or asp.net nears the memory limits, I don't know if
you can control how much flushing occurs. You may want to instead work on
preventing your app from consuming so much memory. You could also look into
strategic use of Dispose() (not always recommended tho).

Also, that 1.8gb setting is when the entire pool will recycle & everything
gets flushed. I believe the .net cache will try to release items before
hitting that cliff, which is why you would see flushing at 1.5gb instead of
1.8gb.

--
Ben Strackany
www.developmentnow.com

<a href="http://www.developmentnow.com">dn</a>


"Dicky Cheng" <xxx (AT) xxx (DOT) com> wrote

Quote:
Hi,
I am using HttpRuntime.Cache.Insert(key, object) to cache some object in
my
web application. I am using IIS 6 and /3GB option to support my 3Gb
physical
memory. I've set the maximum used memory to 1800Mb in the application
pool.
When my web app cache object increase and the private byte nearly 1.5Gb,
the
cache will start flush from 15000 entries to 800 entries and the private
byte become 300Mb now. Can I control the flushing amount (i don't want to
flush nearly all cache objects)? and it is not what I expected that the
app
will nearly 1.8G to start flushing (there still 300M to go).
Thanks in advance,
Dicky Cheng





Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.