Database Cache Management [ASPNET2.0 deep mining series]

Source: Internet
Author: User
Working hours are not short. To tell the truth, I feel more and more depressed: I used to be happy to implement a function for half a day. Now, this feeling is getting farther and farther away from me. Most of my work is Copy, Edit, I don't have any idea at all, and the code myself seems very spam. It is not lazy to modify the code, but sometimes it is because of the constraints of the entire environment that you may not be able to do yourself ......
Okay, don't complain.
Last night, I listened to the 2.0 lecture on database cache management and website page Cache Management in the in-depth mining of ASP. NET 4th series. Benefits. Everything only gets the page cache, and the database cache management has never been tried. Today, I took the opportunity to test the Demo. The effect is good. The configuration in the config file is as follows: 1 <caching>
2 <sqlCacheDependency enabled = "true" pollTime = "1000">
3 <databases>
4 <add name = "lxqq"
5 connectionStringName = "lxqqConnectionString"
6 pollTime = "1000"
7/>
8 </databases>
9 </sqlCacheDependency>
10 </caching>

After configuring the config file, you only need to add the following on the page: <% @ OutputCache Duration = "3600" SqlDependency = "lxqq: module_News "VaryByParam =" none "%> OK !!

If you are interested, you are advised to download microsoft's WebCast. This is a good example from Mr Su Peng !! [Download]

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.