TonWinPkg.Extensions.Caching.Dapr
1.0.2-alpha
dotnet add package TonWinPkg.Extensions.Caching.Dapr --version 1.0.2-alpha
NuGet\Install-Package TonWinPkg.Extensions.Caching.Dapr -Version 1.0.2-alpha
<PackageReference Include="TonWinPkg.Extensions.Caching.Dapr" Version="1.0.2-alpha" />
<PackageVersion Include="TonWinPkg.Extensions.Caching.Dapr" Version="1.0.2-alpha" />
<PackageReference Include="TonWinPkg.Extensions.Caching.Dapr" />
paket add TonWinPkg.Extensions.Caching.Dapr --version 1.0.2-alpha
#r "nuget: TonWinPkg.Extensions.Caching.Dapr, 1.0.2-alpha"
#:package TonWinPkg.Extensions.Caching.Dapr@1.0.2-alpha
#addin nuget:?package=TonWinPkg.Extensions.Caching.Dapr&version=1.0.2-alpha&prerelease
#tool nuget:?package=TonWinPkg.Extensions.Caching.Dapr&version=1.0.2-alpha&prerelease
TonWinPkg.Extensions.Caching.Dapr
Introduction
This package serves as an implementation of Microsoft.Extension.Caching.Abstractions
, providing caching functionality through Dapr's state store component.
Warning
It is advised to consider this package solely as a transitional solution for the following reasons:
- Dapr's state management building block does not implement sliding expiration time. The sliding expiration time implemented by this package is achieved by adding fields to the cached values. Thus, you need to ensure that all read and write operations on the cache are handled through this library.
- Dapr only supports caching data in JSON format and does not support byte arrays. Therefore, this package utilizes Base64 decoding and encoding when reading and writing cache data, resulting in unnecessary performance overhead.
Recommendation
It is recommended to use this library only for feasibility testing of integrating your project with Dapr and not advisable for use in production environments. If you intend to use Dapr for caching operations in a production environment, it is recommended not to use Microsoft.Extensions.Caching.Abstractions
.
Running Tests
Before running, make sure you have initialized Dapr and your state store component is named statestore
.
Run the following command in the test
directory:
dapr run --app-id myapp --dapr-http-port 3500 dotnet test
License
This project is licensed under the terms of the MIT license.
Note: In this document, "Dapr" refers to "Distributed Application Runtime," an open-source project supported by Microsoft.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. 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. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net6.0
- Dapr.Client (>= 1.13.0)
- Microsoft.Extensions.Caching.Abstractions (>= 8.0.0)
- Microsoft.Extensions.Options (>= 8.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.
Version | Downloads | Last Updated |
---|---|---|
1.0.2-alpha | 94 | 4/13/2024 |
1.0.1-alpha | 76 | 4/10/2024 |