473,406 Members | 2,345 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

cache never expires

Asp.net cache expiration isn't working on the host that I've just moved
to. The cache just doesn't expire. It's not the code because it works
fine on my localhost and at my previous hosting provider.

HttpRuntime.Cache.Insert(XmlCacheKey,ds,null,Cache .NoAbsoluteExpiration,
TimeSpan.FromMinutes(1),CacheItemPriority.Normal,s aveData)

I'm using it as a write-back cache that saves the in-memory dataset to
disk every minute if dirty and also on session end, so it's critical
that the cache expires.

I asked my hosting provider if they have disabled expiration using
<cache disableExpiration="false"/and they said no.

Is there any other reason anyone can think of why the cache won't
expire?

Jan 26 '07 #1
4 4740
How often is this item being accessed? If it's being accessed at least once
a minute then it won't expire from the cache. I'm just wondering if there is
something that could be scanning a file that makes use of this cached item,
causing it not to drop out of the cache.
--

Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006


<fn*****@gmail.comwrote in message
news:11**********************@v45g2000cwv.googlegr oups.com...
Asp.net cache expiration isn't working on the host that I've just moved
to. The cache just doesn't expire. It's not the code because it works
fine on my localhost and at my previous hosting provider.

HttpRuntime.Cache.Insert(XmlCacheKey,ds,null,Cache .NoAbsoluteExpiration,
TimeSpan.FromMinutes(1),CacheItemPriority.Normal,s aveData)

I'm using it as a write-back cache that saves the in-memory dataset to
disk every minute if dirty and also on session end, so it's critical
that the cache expires.

I asked my hosting provider if they have disabled expiration using
<cache disableExpiration="false"/and they said no.

Is there any other reason anyone can think of why the cache won't
expire?

Jan 26 '07 #2
Thank you for your reply.

It can't be that because it doesn't expire even when I stop the
application. (normally all cache is expired when application ends)

On Jan 26, 8:10 am, "Mark Fitzpatrick" <markf...@fitzme.comwrote:
How often is this item being accessed? If it's being accessed at least once
a minute then it won'texpirefrom thecache. I'm just wondering if there is
something that could be scanning a file that makes use of this cached item,
causing it not to drop out of thecache.

--

Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006

<fnus...@gmail.comwrote in messagenews:11**********************@v45g2000cwv.g ooglegroups.com...
Asp.netcacheexpiration isn't working on the host that I've just moved
to. Thecachejust doesn'texpire. It's not the code because it works
fine on my localhost and at my previous hosting provider.
HttpRuntime.Cache.Insert(XmlCacheKey,ds,null,Cache .NoAbsoluteExpiration,
TimeSpan.FromMinutes(1),CacheItemPriority.Normal,s aveData)
I'm using it as a write-backcachethat saves the in-memory dataset to
disk every minute if dirty and also on session end, so it's critical
that thecacheexpires.
I asked my hosting provider if they have disabled expiration using
<cachedisableExpiration="false"/and they said no.
Is there any other reason anyone can think of why thecachewon't
expire?- Hide quoted text -- Show quoted text -
Jan 27 '07 #3
I've further narrowed the problem. What is actually happening is the
cache IS expiring but the callback method saveData is not being
called. Again this works fine in the development environment but not
in the hosting environment.

Feb 8 '07 #4
An additional piece of info is that the host environment is win2k3 and
my dev environment is win2k.

Feb 8 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: martin | last post by:
Hi, I am storing a dataset in cache, which is happening fine. I can easily retrive it at postback from the cache, cast it to a dataset and reuse it. However I have specified that the cache...
7
by: C Elson | last post by:
I was hoping someone can help me out. I've searched the pages here and on numerous sites and cannot find an answer that works. I'm trying this code RC4 Encryption/Decryption...
2
by: Promenade | last post by:
Hi, everyone... I want to avoid the user to use the navigator back button. For that reason, I tried all the possible ways to set the Expires property of the Response Object, but whatever I do, it...
1
by: Joe Fallon | last post by:
I am trying to setup a cache that refreshes itself every hour. (My sample code is for every minute so I can test it.) I have found some examples that I thought worked but they all seem to fail....
4
by: NWx | last post by:
Hi, I' trying to implement a callback method when a cache object expires I want to do this to automatically logout user after a timeout (for demo purposes) My thought is, when user logon,...
6
by: Chris | last post by:
In asp we have "Response.Expires = 0" and I've tried: HttpResponse.RemoveOutputCacheItem("page location") But I can't get the page to display new. This is a problem if the data is changed and the...
14
by: Tom.PesterDELETETHISSS | last post by:
Hi, I think this question requires an in depth understanding of how a browser cache works. I hope I can reach an expert here. I may have found a quirk in the asp.net documentation or I don't...
11
by: EagleRed | last post by:
I am writing an ASP.NET 2.0 application that uses master pages. I have some pages that must not be cached on the client. In ASP.NET 1.1 I achieved this using metatags: <meta...
2
by: wpt394 | last post by:
Hello everyone, I have a little script that seems to hang up in internet explorer every now and again. Basically, I have a php page that sets the following headers: header(...
2
by: WALDO | last post by:
I am having the exact same problem. I am using VS2008 (.Net 3.5) and I can't set the Expires date out any further than one day. Doing a little reflection, I see that in the HttpCachePolicy class,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.