Cache: Application or Session?

  • Thread starter Greg Collins [MVP]
  • Start date
G

Greg Collins [MVP]

I think I know the answer, but I need to be absolutely sure.

Currently I'm using Cache.Insert() -- Is this an Application level or Session level Cache? As far as I can tell there's only 1 Cache object and it's Application level, but if I'm misguided on that, I want to make sure I'm using the Application Cache and not the Session Cache.

Thanx again in advance!
 
K

Karl Seguin

Greg:
i have an article which discusses ASP.Net storage mechanisms at
http://openmymind.net/DataStorage/index.html

HttpCache is application level, however you could turn it into somewhat of a
session level via the cacheKey:

string cacheKey = "GetUserSettings:" + userId.ToString()

at which point the cached information is specific to a user (although it's
still accessible throughout the application)...

Hope this helps,
Karl
--
MY ASP.Net tutorials
http://www.openmymind.net/


"Greg Collins [MVP]" <Greg.Collins_AT_InfoPathDev.com> wrote in message
I think I know the answer, but I need to be absolutely sure.

Currently I'm using Cache.Insert() -- Is this an Application level or
Session level Cache? As far as I can tell there's only 1 Cache object and
it's Application level, but if I'm misguided on that, I want to make sure
I'm using the Application Cache and not the Session Cache.

Thanx again in advance!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,065
Latest member
OrderGreenAcreCBD

Latest Threads

Top