CacheLink: Efficient Multi-Device Secondary Caching for RocksDB
Agung Rahmat Ramadhan, Seehwan Yoo, Jongmoo ChoiSecondary caching is increasingly important for RocksDB deployments on remote or disaggregated storage, where misses in the DRAM block cache incur costly backend reads. Although RocksDB introduced the experimental SecondaryCache interface to extend block caching beyond DRAM, practical public support remains limited and does not fully exploit heterogeneous local storage devices. We present CacheLink, a multi-device secondary caching framework for RocksDB that extends the SecondaryCache model with practical cache-management capabilities using CacheLib. CacheLink stores blocks evicted from the DRAM block cache on heterogeneous secondary devices such as HDDs, SSDs, and NVMe drives, thereby reducing access to slower backing storage. It further supports configurable random admission control and multiple eviction policies, including LRU, LRU2Q, and TinyLFU. Experimental results obtained using db_bench and YCSB show that CacheLink substantially improves throughput and reduces latency compared to baseline RocksDB without secondary caching. In the secondary cache size experiment, the best-performing configuration uses a 2 GB NVMe secondary cache with TinyLFU eviction and full admission, improving throughput by 2.5× and reducing average latency by 60.7% relative to the baseline.