Conclusion


Conclusion

Caching is one of the easiest and most well-understood ways of wringing better performance out of an application. ASP.NET implements an easy-to-use application cache. The application cache stores any CLR object and is available at any time while processing a request. You can dig it out of the current context (the HttpContext), and it's also available as a member variable of System.Web.UI.Page.

Probably the most common way to use the cache is to store database query results to avoid round-trips to a database. Accessing memory is often orders of magnitude faster than hitting the database. In addition, you sidestep issues such as limited connection resources and database contention.

While you can effectively improve the performance of your application by simply putting items in the cache, ASP.NET's caching mechanism provides facilities for putting limits on the amount of time items remain cached. You may also set up dependencies between cached items and their physical data sources so that you may be alerted when items need to be reloaded into the cache.




Microsoft ASP. NET 2.0 Programming Step by Step
Microsoft ASP.NET 2.0 Step By Step (Step By Step (Microsoft))
ISBN: B002KE5VYO
EAN: N/A
Year: 2005
Pages: 177

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net