Groups | Blog | Home
all groups > asp.net caching > january 2005 >

asp.net caching : Difference in accessing Cache



Todd Price
1/27/2005 7:53:05 AM
Does anyone have any recommendations on whether to use
System.Web.HttpContext.Current.Cache or System.Web.HttpRuntime.Cache to
access the ASP.NET Cache? Are these different cache contexts? If they are
Alvin Bruney [MVP]
1/29/2005 8:42:52 PM
No, they are basically the same underneath.

--
Regards,
Alvin Bruney

[Shameless Author plug]
The Microsoft Office Web Components Black Book with .NET
Now Available @ www.lulu.com/owc
----------------------------------------------------------


[quoted text, click to view]

Ben Strackany
2/7/2005 12:37:09 PM
Alvin, that is truly a shamless author plug. Heh, no, just kidding. :)

Todd, one thing to note is than a few places in the MSDN documentation, it
erroneously implies that System.Web.HttpContext.Current.Cache is some sort
of temporary, page-execution-only cache. That's not the case.

--
Ben Strackany
www.developmentnow.com


[quoted text, click to view]

Alvin Bruney [MVP]
2/8/2005 10:11:57 AM
I did say it was shameless...

--
Regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
The Microsoft Office Web Components Black Book with .NET
Now Available @ http://tinyurl.com/27cok
----------------------------------------------------------


[quoted text, click to view]

Paul Wu
6/18/2005 7:36:30 PM
They are functionally the same but make sure you don't set the cache with one and read it using the other. It won't work reliably.


Paul Wu
www.rulemasters.com


From http://developmentnow.com/g/11_2005_1_0_0_47166/Difference-in-accessing-Cache.htm

Posted via DevelopmentNow.com Groups
AddThis Social Bookmark Button