Changes all instances of the legacy Cache class to be using ApplicationContext.Current.ApplicationCache.

Fixes: #U4-2039 - ensures macro xslt cache is invalidated in LB scenarios.
This commit is contained in:
Shannon Deminick
2013-04-03 23:39:51 +06:00
parent e14d3fd379
commit 2a7e493c74
9 changed files with 76 additions and 54 deletions

View File

@@ -46,22 +46,22 @@ namespace Umbraco.Core.Cache
return getCacheItem();
}
public override T GetCacheItem<T>(string cacheKey, TimeSpan timeout, Func<T> getCacheItem)
public override T GetCacheItem<T>(string cacheKey, TimeSpan? timeout, Func<T> getCacheItem)
{
return getCacheItem();
}
public override T GetCacheItem<T>(string cacheKey, CacheItemRemovedCallback refreshAction, TimeSpan timeout, Func<T> getCacheItem)
public override T GetCacheItem<T>(string cacheKey, CacheItemRemovedCallback refreshAction, TimeSpan? timeout, Func<T> getCacheItem)
{
return getCacheItem();
}
public override T GetCacheItem<T>(string cacheKey, CacheItemPriority priority, CacheItemRemovedCallback refreshAction, TimeSpan timeout, Func<T> getCacheItem)
public override T GetCacheItem<T>(string cacheKey, CacheItemPriority priority, CacheItemRemovedCallback refreshAction, TimeSpan? timeout, Func<T> getCacheItem)
{
return getCacheItem();
}
public override T GetCacheItem<T>(string cacheKey, CacheItemPriority priority, CacheItemRemovedCallback refreshAction, CacheDependency cacheDependency, TimeSpan timeout, Func<T> getCacheItem)
public override T GetCacheItem<T>(string cacheKey, CacheItemPriority priority, CacheItemRemovedCallback refreshAction, CacheDependency cacheDependency, TimeSpan? timeout, Func<T> getCacheItem)
{
return getCacheItem();
}
@@ -70,11 +70,11 @@ namespace Umbraco.Core.Cache
{
}
public override void InsertCacheItem<T>(string cacheKey, CacheItemPriority priority, TimeSpan timeout, Func<T> getCacheItem)
public override void InsertCacheItem<T>(string cacheKey, CacheItemPriority priority, TimeSpan? timeout, Func<T> getCacheItem)
{
}
public override void InsertCacheItem<T>(string cacheKey, CacheItemPriority priority, CacheDependency cacheDependency, TimeSpan timeout, Func<T> getCacheItem)
public override void InsertCacheItem<T>(string cacheKey, CacheItemPriority priority, CacheDependency cacheDependency, TimeSpan? timeout, Func<T> getCacheItem)
{
}