UmbracoOutputCache 1.0.0
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package UmbracoOutputCache --version 1.0.0
NuGet\Install-Package UmbracoOutputCache -Version 1.0.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="UmbracoOutputCache" Version="1.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add UmbracoOutputCache --version 1.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: UmbracoOutputCache, 1.0.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install UmbracoOutputCache as a Cake Addin #addin nuget:?package=UmbracoOutputCache&version=1.0.0 // Install UmbracoOutputCache as a Cake Tool #tool nuget:?package=UmbracoOutputCache&version=1.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Setup procedure
The appsettings.json
file can be used to change the OutputCache LifeSpanInSeconds as shown below
{
"OutputCacheSettings":
{
"CacheLifeSpanInSeconds": 5
}
}
The following Sample code, will make sure that the output that this controller produces is Cached for 5 seconds and any code in the razor views will not be executed for 5 seconds no matter how many concurrent visitors.
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.ViewEngines;
using Microsoft.AspNetCore.OutputCaching;
using Microsoft.Extensions.Logging;
using OutputCaching.Core.Setup;
using Umbraco.Cms.Core.Web;
using Umbraco.Cms.Web.Common.Controllers;
namespace DemoNamespace
{
public class MyRenderController : RenderController
{
public MyRenderController(
ILogger<MyRenderController> logger,
ICompositeViewEngine compositeViewEngine,
IUmbracoContextAccessor umbracoContextAccessor)
: base(logger, compositeViewEngine, umbracoContextAccessor)
{
}
[OutputCache(PolicyName = OutputCacheComponent.CachePolicyName)]
public override IActionResult Index()
{
return base.Index();
}
}
}
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net7.0 is compatible. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. 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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net7.0
- Umbraco.Cms.Web.BackOffice (>= 11.1.0)
- Umbraco.Cms.Web.Website (>= 11.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
14.2.0 | 214 | 9/13/2024 |
14.1.0 | 177 | 9/13/2024 |
13.0.0 | 493 | 12/16/2023 |
12.0.0 | 300 | 7/1/2023 |
11.2.2 | 844 | 1/31/2023 |
11.2.1 | 323 | 1/31/2023 |
11.2.0 | 289 | 1/30/2023 |
11.1.10 | 302 | 1/29/2023 |
11.1.9 | 290 | 1/29/2023 |
11.1.8 | 306 | 1/21/2023 |
11.1.7 | 309 | 1/20/2023 |
11.1.6 | 279 | 1/20/2023 |
11.1.5 | 284 | 1/20/2023 |
11.1.4 | 299 | 1/20/2023 |
11.1.3 | 326 | 1/17/2023 |
11.1.2 | 301 | 1/17/2023 |
11.1.1 | 296 | 1/17/2023 |
11.1.0 | 310 | 1/15/2023 |
1.1.1 | 299 | 1/15/2023 |
1.0.0 | 299 | 1/15/2023 |