More in this section

Forums / General Discussions / Database Cacheing

Database Cacheing

2 posts, 1 answered
  1. vinamra
    vinamra avatar
    45 posts
    23 Oct 2012
    20 May 2010
    Link to this post

    How to enable database cacheing.

    i am using sitefinity 3.7 sp3.

  2. Radoslav Georgiev
    Radoslav Georgiev avatar
    3370 posts
    01 Feb 2016
    21 May 2010
    Link to this post
    Hello vinamra,

    Thank you for using our services.

    If you wish to use caching so that your CMS pages are cached, you can go to the properties section of your page and expand the More options section. There you have Enable caching option. Or you can do this in the web.config file so this applied globally to all of your pages:
    <cms defaultProvider="Sitefinity" pageExtension=".aspx" disabled="false"
            <defaultProperties requireCaching="true" navigable="true" disableViewState="false" requireSSL="false" />

    By default all cache date is stored in the server memory. We do have a setting which lets you define where the data providers using caching on your website should check if the cache is valid or not. There is a choice for this - either in the server's memory or in database. If you choose to use the in database option then your website will still cache in the memory, however the information whether a cached item is valid or expired will be stored in the database. Also when a page has been edited the value in database will be cleared telling the website that the page's cache is no longer valid ans should be re-cached. This option is preferable if you use a web farm or other load balancing environment, where you have several servers hosting the same site, connected to one and the same database. To set cache dependencies to be recorded in database you have to modify the bellow setting in your web.config:
    <caching defaultProvider="memoryCache">
        <cacheDependency mode="InDatabase" />

    We have tested performance if the caching providers save the actual cache in the database and our tests show that this approach is not faster than using the server's memory. After all you have to go to the database and pull data and get it back to the server as opposed to just getting it from the server.

    Kind regards,
    Radoslav Georgiev
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
2 posts, 1 answered