User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the RSS, Web Services and SOAP section within the Web Development category of DaniWeb, a massive community of 423,502 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 4,694 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our RSS, Web Services and SOAP advertiser: Programming Forums
Views: 931 | Replies: 0
Reply
Join Date: May 2008
Posts: 18
Reputation: nmpgaspar is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 0
nmpgaspar nmpgaspar is offline Offline
Newbie Poster

Detect expiration in Web.Caching.Cache on a webservice

  #1  
May 27th, 2008
Hey.

I'm using System.Web.Caching in my .asmx webservice in order to save some information about multiple users requests.

I insert that data like this:
cache.Insert(Unique_token, MySessionObjectForThatUserToken, null, Cache.NoAbsoluteExpiration, new TimeSpan(0, 15, 0));

And then retrieve it like this:
MySessionObjectForThatUserToken obj = (MySessionObjectForThatUserToken)cache[token];

As you can see, i have a slidding expiration time of 15minutes. So now, what i wanna know, is if it's possible to have some event that will fire whenever an object gets expired from the cache?

How can i archive this?
I would just need to know, what is the 'token' associated with the expired object.
AddThis Social Bookmark Button
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb RSS, Web Services and SOAP Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Other Threads in the RSS, Web Services and SOAP Forum

All times are GMT -4. The time now is 4:18 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC