Last post Nov 13, 2014 03:16 AM by Shawn - MSFT
Nov 12, 2014 04:07 PM|neoaguil17|LINK
I use Cache.Insert("PermisosUsuario", lista, null, DateTime.Now.AddHours(12), TimeSpan.Zero) in aspnet
and httpcontext.current.cache for wcf
but what's the max memory size by default for the cache memory in the 2 cases.
Nov 12, 2014 04:25 PM|sen338|LINK
It depends on how much memory you have and also your IIS / ASP.Net configuration, please follow the below post
Nov 13, 2014 03:16 AM|Shawn - MSFT|LINK
The <caching> element is included in the default installation of IIS 7. You can configure the <caching> element at the server level in the ApplicationHost.config file or at the site, application, or at the directory level in a Web.config file.
Cache size limit (in MB) Configures the size limit of both the user-mode and kernel-mode caches. You can type a size (in MB) or type 0. If you type 0, IIS uses half of the available physical memory or virtual memory, whichever is less. This
field is enabled at the server level only; it is read-only at all other levels.
Maximum cached response size (in bytes) Specifies the maximum size of a cached response for both the user-mode and kernel-mode caches. The default value is 262144 bytes. This field is enabled at the server level only; it is read-only at
all other levels.
For detailed information, you could refer to:
And caching in WCF, you could try to use physicalMemoryLimitPercentage property: