.NET client for Redis, Redis Sentinel and Redis Cluster
open sourceMITfree
CSRedis is a Redis client for .NET Core and .NET Framework 4.0+, with synchronous and asynchronous methods named like the redis-cli commands. It supports a single server, Redis Sentinel with master and replica, Redis Cluster (following MOVED and ASK redirects), client-side partitioning across servers, connection pooling, pipelines, pub/sub, geo commands and streams. The RedisHelper static class wraps a singleton client, and the separate Caching.CSRedis package provides an IDistributedCache for ASP.NET Core. Install it from NuGet as CSRedisCore. Much of the README is in Chinese.
Problems it solves
- connect an ASP.NET Core app to Redis Sentinel with automatic failover
- use Redis as IDistributedCache in .NET with a simple static helper
- talk to a Redis Cluster from a .NET Framework 4 app
Features
- sync and async methods named after redis-cli commands
- Redis Sentinel and Redis Cluster
- client-side partitioning
- connection pooling and pipelines
- pub/sub, geo and stream commands
- IDistributedCache package for ASP.NET Core
Limitations
- Much of the README is in Chinese.1
Alternatives
The same job
These do what CSRedis does.
- StackExchange.Redis The Redis client for .NET
