nightmaregaurav.rediscachehelper
2.0.0
dotnet add package nightmaregaurav.rediscachehelper --version 2.0.0
NuGet\Install-Package nightmaregaurav.rediscachehelper -Version 2.0.0
<PackageReference Include="nightmaregaurav.rediscachehelper" Version="2.0.0" />
paket add nightmaregaurav.rediscachehelper --version 2.0.0
#r "nuget: nightmaregaurav.rediscachehelper, 2.0.0"
// Install nightmaregaurav.rediscachehelper as a Cake Addin #addin nuget:?package=nightmaregaurav.rediscachehelper&version=2.0.0 // Install nightmaregaurav.rediscachehelper as a Cake Tool #tool nuget:?package=nightmaregaurav.rediscachehelper&version=2.0.0
RedisCacheHelper
RedisCacheHelper is a C# utility library that provides caching functionality using the StackExchange.Redis library without DI. It simplifies the process of storing and retrieving data from a Redis cache, allowing for efficient and reliable caching of objects.
Features
- Simple and intuitive API for caching operations.
- Supports synchronous and asynchronous caching methods.
- Allows caching with optional expiration times.
- Provides synchronization of data retrieval using a provided function.
Usage
- Install the package from NuGet.
- Add these somewhere in your appsettings.json:
"Redis": {
"Host": "your.redis.host",
"Port": "PORT",
"Password": "xxxxxxxxxx",
"Prefix": "keyPrefix:"
}
- Use in code
// Example usage of RedisCacheHelper
using RedisCacheHelper;
// Rest of the codes...
//
CacheHelper.Set("myKey", myObject);
var cachedObject = CacheHelper.Get<MyType>("myKey");
//
// Rest of the codes...
License
RedisCacheHelper is released under the MIT License. You can find the full license details in the LICENSE file.
Made with ❤️ by NightmareGaurav.
Open For Contribution
We welcome contributions from the community! If you find any issues or have suggestions for improvements, feel free to open a pull request or issue. Your contributions help make this project better for everyone.
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. |
-
net7.0
- nightmaregaurav.exceptionsafe (>= 1.0.1)
- nightmaregaurav.staticappsettings (>= 2.0.0)
- nightmaregaurav.systemtextjsonhelper (>= 2.0.0)
- StackExchange.Redis (>= 2.6.122)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.