Try our conversational search powered by Generative AI!

Caching in Community

Vote:
 

Hi,

There's a cache element in web.config:





Looking at the code absoluteExpirationIncrement and slidingExpiration attributes can be specified as well but I cant find any docs on it?

Also, if you dont specifiy these in the element it uses System.Web.Caching.Cache.NoAbsoluteExpiration and System.Web.Caching.Cache.NoSlidingExpiration defaults - is that correct?

Cheers

#151208
Jul 13, 2016 12:18
Vote:
 

Yes, absoluteExpirationIncrement and slidingExpiration attributes can be specified in web.config, but only one at a time.

Both are TimeSpan values, absoluteExpirationIncrement stating the time from creation of the cached object until it expires, slidingExpiration the time from last access of the cached object until it expires.

You are also correct, System.Web.Caching.Cache.NoAbsoluteExpiration and System.Web.Caching.Cache.NoSlidingExpiration are the default settings.

#154283
Aug 29, 2016 16:47
Vote:
 

Thanks Joakim, 

So with neither absoluteExpirationIncrement nor slidingExpiration set in my web.config, caching is effectively turned off for Community right now?

How does this relate to any caching at the API level – so calls through the ForumHandler for example, to GetForums() - is the framework caching these like normal EPiServer CMS is and is this cache effected by the above settings?

#154292
Aug 30, 2016 9:24
Vote:
 

Hi Neil,

With neither absoluteExpirationIncrement nor slidingExpiration set in your web.config, caching is turned on and objects are by default stored in cache indefinitely, until they are evicted to make room for new objects.

Community caches as defined in the settings provided to EPiServer.Common.Cache, whereas CMS has its own handling. Community and CMS do however share the same underlying cache.

#154817
Aug 30, 2016 15:25
This thread is locked and should be used for reference only. Please use the Legacy add-ons forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.