Files
Umbraco-CMS/src/Umbraco.Web/Cache/DistributedCacheBinderComposer.cs

20 lines
698 B
C#
Raw Normal View History

2019-01-03 21:00:28 +01:00
using Umbraco.Core;
using Umbraco.Core.Components;
using Umbraco.Core.Composing;
namespace Umbraco.Web.Cache
{
/// <summary>
/// Installs listeners on service events in order to refresh our caches.
/// </summary>
[RuntimeLevel(MinLevel = RuntimeLevel.Run)]
2019-01-04 10:29:29 +01:00
[ComposeBefore(typeof(ICoreComposer))] // runs before every other IUmbracoCoreComponent!
2019-01-03 21:00:28 +01:00
public sealed class DistributedCacheBinderComposer : ICoreComposer
{
public void Compose(Composition composition)
{
composition.RegisterUnique<IDistributedCacheBinder, DistributedCacheBinder>();
composition.Components().Append<DistributedCacheBinderComponent>();
}
}
}