Cleanup - more distributed cache cleanup

This commit is contained in:
Stephan
2016-06-08 14:19:15 +02:00
parent ecadb918f2
commit ffeeb4f7d4
8 changed files with 22 additions and 50 deletions

View File

@@ -753,7 +753,7 @@ namespace Umbraco.Web.PublishedCache.NuCache
{
switch (payload.ChangeType)
{
case DomainCacheRefresher.ChangeTypes.RefreshAll:
case DomainChangeTypes.RefreshAll:
var domainService = _serviceContext.DomainService as DomainService;
if (domainService == null) throw new Exception("oops");
using (var uow = _uowProvider.CreateUnitOfWork())
@@ -763,10 +763,10 @@ namespace Umbraco.Web.PublishedCache.NuCache
uow.Complete();
}
break;
case DomainCacheRefresher.ChangeTypes.Remove:
case DomainChangeTypes.Remove:
_domainStore.Clear(payload.Id);
break;
case DomainCacheRefresher.ChangeTypes.Refresh:
case DomainChangeTypes.Refresh:
var domain = _serviceContext.DomainService.GetById(payload.Id);
if (domain == null) continue;
if (domain.RootContentId.HasValue == false) continue; // anomaly