MVCCaching.Base.Core.Components
8.0.0
dotnet add package MVCCaching.Base.Core.Components --version 8.0.0
NuGet\Install-Package MVCCaching.Base.Core.Components -Version 8.0.0
<PackageReference Include="MVCCaching.Base.Core.Components" Version="8.0.0" />
paket add MVCCaching.Base.Core.Components --version 8.0.0
#r "nuget: MVCCaching.Base.Core.Components, 8.0.0"
// Install MVCCaching.Base.Core.Components as a Cake Addin #addin nuget:?package=MVCCaching.Base.Core.Components&version=8.0.0 // Install MVCCaching.Base.Core.Components as a Cake Tool #tool nuget:?package=MVCCaching.Base.Core.Components&version=8.0.0
MVCCaching Base and Components
This readme is specifically for the Platform Agnostic MVCCaching packages. If you are using this for Xperience by Kentico, or Kentico Xperience 13, please see those specific readmes.
Concept
I believe caching should be a common optimization practice. Caching, at it's core, consists of these core elements:
- What to cache (the object)
- What is that cached call's unique identifier (it's Name)
- How long should something be cached (it's Duration)
- What triggers should clear the cache prematurely (it's Dependencies)
Along with that, there may be things that caches often need to know:
- Language
- If caching should be disabled (IE Preview mode)
Lastly, in terms of usage of the <cache>
tag within ASP.Net Core MVC, you also often need:
- Cache Dependencies for the
<cache>
tag - Cache Scope (to determine the dependencies called within the scope that should pass to the cache tag's dependencies)
- Cache Store (a way to store dependencies as they are generated)
The Tool
MVCCaching.Base.Core
Provides interfaces, extension methods and helpers to accomplish these concepts. These do not, however, actually implement them, as that varies.
MVCCaching.Base.Core.Components
also provides Tag Helpers that extend the <cache>
tag, and add the <cache-dependency-keys>
child tag to allow passing of those dependencies.
Additionally, although not caching related, Dependency Injection automation is also something often employed and is included.
Extending
These packages have implementations in Kentico Xperience 13 and Xperience by Kentico, however there is nothing preventing implementations to be written for other platforms, or just MVC itself (using memory cache for example).
If you wish to use these base items and write other implementations, feel free to fork and make a pull request!
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net8.0
- Microsoft.AspNetCore.Mvc.TagHelpers (>= 2.2.0)
- MVCCaching.Base.Core (>= 4.5.0)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on MVCCaching.Base.Core.Components:
Package | Downloads |
---|---|
XperienceCommunity.DevTools.MVCCaching
Adjusted Get Default Language to fall back to Content Default Language. Changed ICachingReferenceService to ICacheReferenceService to fit other ICache motif. |
GitHub repositories
This package is not used by any popular GitHub repositories.
Updated to .net 8.0