# garnet **Repository Path**: cdevel/garnet ## Basic Information - **Project Name**: garnet - **Description**: No description available - **Primary Language**: C# - **License**: MIT - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-04-23 - **Last Updated**: 2026-06-22 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Garnet [](https://github.com/microsoft/garnet/actions/workflows/ci.yml) [](https://github.com/microsoft/garnet/releases/latest) [](https://www.nuget.org/packages/microsoft.garnet) [](https://www.nuget.org/packages/garnet-server) [](https://microsoft.github.io/garnet/charts/) [](https://aka.ms/garnet-discord) Garnet is a new remote cache-store from Microsoft Research, that offers several unique benefits: * Garnet adopts the popular [RESP](https://redis.io/docs/latest/develop/reference/protocol-spec/) wire protocol as a starting point, which makes it possible to use Garnet from unmodified Redis clients available in most programming languages of today, such as [StackExchange.Redis](https://github.com/StackExchange/StackExchange.Redis) in C#. * Garnet offers much better throughput and scalability with many client connections and small batches, relative to comparable open-source cache-stores, leading to cost savings for large apps and services. * Garnet demonstrates extremely low client latencies (often less than 300 microseconds at the 99.9th percentile) using commodity cloud (Azure) VMs with Accelerated Networking enabled, which is critical to real-world scenarios. * Based on the latest .NET technology, Garnet is cross-platform, extensible, and modern. It is designed to be easy to develop for and evolve, without sacrificing performance in the common case. We leveraged the rich library ecosystem of .NET for API breadth, with open opportunities for optimization. Thanks to our careful use of .NET, Garnet achieves state-of-the-art performance on both Linux and Windows. This repo contains the code to build and run Garnet. For more information and documentation, check out our website at [https://microsoft.github.io/garnet](https://microsoft.github.io/garnet). **Looking for a fully managed service?** [Azure Cosmos DB Garnet Cache](https://microsoft.github.io/garnet/docs/azure/overview) provides Garnet as a fully managed, enterprise-ready caching solution with built-in high availability, performance guarantees and zero infrastructure management. ## What's New 🎉 - **🚀 [Vector Sets (Preview)](https://microsoft.github.io/garnet/docs/commands/vector-sets)** — Approximate nearest-neighbor search backed by the [DiskANN](https://github.com/microsoft/DiskANN) algorithm and Garnet's Tsavorite storage engine. In our [initial results](https://github.com/microsoft/DiskANN/wiki/Perf:-Garnet-Providers-vs-other-Vector-DBs-(Zilliz,-Pinecone,-etc.)), Garnet leads on QPS, p99 latency, and recall. - **🔍 [Range Index (Preview)](https://microsoft.github.io/garnet/docs/commands/range-index)** — Secondary range and equality indexes over Garnet keys, powered by [Bf-Tree](https://github.com/microsoft/bf-tree). - **📄 The Garnet paper will appear at VLDB 2026!** B. Chandramouli, V. Zois, T. Hart, T. Zaccai, L. M. Maas, Y. Rajasekaran, D. Gehring. *Garnet: A Next-Generation Cache-Store for Accelerating Applications and Services.* PVLDB 2026. [[PDF]](https://www.vldb.org/pvldb/vol19/p224-chandramouli.pdf) ## Feature Summary Garnet implements a wide range of APIs including raw strings (e.g., gets, sets, and key expiration), analytical (e.g., HyperLogLog and Bitmap), and object (e.g., sorted sets and lists) operations. It can handle multi-key transactions in the form of client-side RESP transactions and our own server-side stored procedures and modules in C#. It allows users to define custom operations on both raw strings and custom object types, all in the convenience and safety of C#, leading to a lower bar for developing custom extensions. Garnet also supports Lua scripts. Garnet uses a fast and pluggable network layer, enabling future extensions such as leveraging kernel-bypass stacks. It supports secure transport layer security (TLS) communications using the robust [SslStream](https://learn.microsoft.com/en-us/dotnet/api/system.net.security.sslstream) library of .NET, as well as basic access control. Garnet’s storage layer, called Tsavorite, is built for high performance and includes strong database features such as thread scalability, tiered storage support (memory, SSD, and cloud storage), fast non-blocking checkpointing, recovery, operation logging for durability, multi-key transaction support, and better memory management and reuse. Finally, Garnet supports a cluster mode of operation with support for sharding, replication, and dynamic key migration.