StackExchange.Redis is a high performance general purpose redis client for .NET languages (C#, etc.). It is the logical successor to BookSleeve, and is the client developed-by (and used-by) Stack Exchange for busy sites like Stack Overflow. For the full reasons why this library was created (i.e. "What about BookSleeve?") please see here.
- High performance multiplexed design, allowing for efficient use of shared connections from multiple calling threads
- Abstraction over redis node configuration: the client can silently negotiate multiple redis servers for robustness and availability
- Convenient access to the full redis feature-set
- Full dual programming model both synchronous and asynchronous usage, without requiring "sync over async" usage of the TPL
- Support for redis "cluster"
StackExchange.Redis can be installed via the nuget UI (as StackExchange.Redis), or via the nuget package manager console:
PM> Install-Package StackExchange.Redis- Server - running a redis server
- Basic Usage - getting started and basic usage
- Async Timeouts - async timeouts and cancellation
- Configuration - options available when connecting to redis
- Pipelines and Multiplexers - what is a multiplexer?
- Keys, Values and Channels - discusses the data-types used on the API
- Transactions - how atomic transactions work in redis
- Events - the events available for logging / information purposes
- Pub/Sub Message Order - advice on sequential and concurrent processing
- Pub/Sub Key Notifications - how to use keyspace and keyevent notifications
- Hot Keys - how to use
HOTKEYSprofiling - Using RESP3 - information on using RESP3
- ServerMaintenanceEvent - how to listen and prepare for hosted server maintenance (e.g. Azure Cache for Redis)
- Streams - how to use the Stream data type
- Where are
KEYS/SCAN/FLUSH*? - how to use server-based commands - Profiling - profiling interfaces, as well as how to profile in an
asyncworld - Scripting - running Lua scripts with convenient named parameter replacement
- Testing - running the
StackExchange.Redis.Testssuite to validate changes - Timeouts - guidance on dealing with timeout problems
- Thread Theft - guidance on avoiding TPL threading problems
- RESP Logging - capturing and validating RESP streams
If you think you have found a bug or have a feature request, please report an issue, or if appropriate: submit a pull request. If you have a question, feel free to contact me.