1 Replies - 1318 Views - Last Post: 16 August 2013 - 07:17 AM Rate Topic: -----

#1 Grandville  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 24
  • Joined: 06-October 09

ASP Web Service Caching

Posted 16 August 2013 - 02:43 AM

Hi All,

Im trying to implement caching in an ASP web sevice and was wondering what the difference (if any) there is between adding objects to the cache with the following methods:

Application("productCache") = productCollection
or
HttpContext.Current.Cache.Insert("CacheItem", productCollection)

I will be caching a full product list to make available to all users so subsequent product searches dont result in numerous hits on the database, but rather retrieve from the cache instead.

One other thing also is how the expiration period is implied with the Application("") method, since the HttpContext....choice allows you to specify an expiration date/time as part of the insert.

Thanks for your time.

This post has been edited by Grandville: 16 August 2013 - 02:45 AM


Is This A Good Question/Topic? 0
  • +

Replies To: ASP Web Service Caching

#2 modi123_1  Icon User is offline

  • Suitor #2
  • member icon



Reputation: 8937
  • View blog
  • Posts: 33,462
  • Joined: 12-June 08

Re: ASP Web Service Caching

Posted 16 August 2013 - 07:17 AM

Have you flipped through this link? ASP.NET Caching: Techniques and Best Practices
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1