MVCCaching.Kentico
12.29.2
See the version list below for details.
dotnet add package MVCCaching.Kentico --version 12.29.2
NuGet\Install-Package MVCCaching.Kentico -Version 12.29.2
<PackageReference Include="MVCCaching.Kentico" Version="12.29.2" />
paket add MVCCaching.Kentico --version 12.29.2
#r "nuget: MVCCaching.Kentico, 12.29.2"
// Install MVCCaching.Kentico as a Cake Addin #addin nuget:?package=MVCCaching.Kentico&version=12.29.2 // Install MVCCaching.Kentico as a Cake Tool #tool nuget:?package=MVCCaching.Kentico&version=12.29.2
Upgrade Error
If you are upgrading from 12.29.0 or 12.29.1, or if you receive an error concerning Castle.Core assembly, please look in your web.config's assemblyBinding and update the Castle.Core binding to this:
<dependentAssembly>
<assemblyIdentity name="Castle.Core" publicKeyToken="407dd0808d44fbdc" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.0.0.0" />
</dependentAssembly>
MVC Caching
MVC Caching for Kentico MVC, extending the DancingGoat Caching Implementation to allow for easy Caching both of Repository calls, database calls, and Output Caching. Sets up and leverages Kentico's cache dependencies.
Installation for Kentico MVC Site (Quick)
- Install the
MVCCaching.Kentico
NuGet Package to your MVC Site - Add this to your Global.asax.cs's Application_Start
#region "AutoFac Cache and other dependency injections"
// Register AutoFac Items
var builder = new ContainerBuilder();
// Register Dependencies for Cache
DependencyResolverConfig.Register(builder);
// Set Autofac Dependency resolver to the builder
DependencyResolver.SetResolver(new AutofacDependencyResolver(builder.Build()));
#endregion
- Optionally create an override the GetVaryByCustomString method to your Application (see the sample Globa.asax.cs GetVaryByCustomString method).
Installation for Kentico MVC Site (Manual)
- Install the
MVCCaching.Base
NuGet Package to your MVC Site - Go to the MVCCaching.Kentico Folder on GitHub
- Copy and include the Infrastructure into your Kentico MVC Site
- Add the code found in the Global.asax.cs Application_Start method into your application's Application_Start
- Optionally add the Globa.asax.cs GetVaryByCustomString method.
Usage
- See Documentation.md for full documentation
Learn more about Target Frameworks and .NET Standard.
-
- Autofac (>= 4.9.2)
- Autofac.Extras.DynamicProxy (>= 4.3.0)
- MVCCaching.Base (>= 1.0.2)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Added two attributes (CacheNameNoCulture and CacheNameNoSite) to exclude these from the cache key name generation, and updated the CachingRepositoryDecorator to automatically include Cache Dependencies into the OutputCache, and updated the DependencyResolverConfig to include the IOutputCacheDependencies to the CachingRepositoryDecorator