Spooky: Granulating LSM-Tree Compactions Correctly
Niv Dayan, Tamar Weiss, Shmuel Dashevsky, Michael Pan, Edward Bortnikov, Moshe Twitto
摘要
Modern storage engines and key-value stores have come to rely on the log-structured merge-tree (LSM-tree) as their core data structure. LSM-tree operates by gradually merge-sorting data across levels of exponentially increasing capacities in storage. A crucial design dimension of LSM-tree is its compaction granularity. Some designs perform Full Merge, whereby entire levels get compacted at once. Others perform Partial Merge, whereby smaller groups of files with overlapping key ranges are compacted independently. This paper shows that both strategies exhibit serious flaws. With Full Merge, space-amplification is exorbitant. The reason is that while compacting the LSM-tree's largest level, there must be at least twice as much storage space as data to store both the original and new files until the compaction is finished. On the other hand, Partial Merge exhibits excessive write-amplification. The reason is twofold. (1) The files getting compacted typically do not have perfectly overlapping key ranges, and so some non-overlapping data is superfluously rewritten in each compaction. (2) Files with different lifetimes become interspersed within the SSD leading to high SSD garbage-collection overheads. As the data size grows, these problems grow in magnitude. We introduce Spooky, a novel compaction granulation method to address these problems. Spooky partitions data at the largest level into equally sized files, and it partitions data at smaller levels based on the file boundaries at the largest level. This allows merging one group of perfectly overlapping files at a time to limit spaceamplification and compaction overheads. At the same time, Spooky writes larger though fewer files simultaneously so that files with different lifetimes do not become as interspersed within the SSD. This cheapens garbage-collection. We show empirically that Spooky achieves >2x lower space-amplification than Full Merge and >2x lower write-amplification than Partial Merge at the same time.
问问这篇 Paper
智能体会读完全文。
Lune 把这篇 Paper 索引到了每一个公式,引用它的顶会 Paper 也一样。你提问,回答直接引用原文。
引用它的顶会 Paper20
- Learning to Optimize LSM-trees: Towards A Reinforcement Learning based Key-Value Store for Dynamic WorkloadsDingheng Mo, Fanchao Chen, Siqiang Luo, Caihua ShanSIGMOD 2024 · 被引用 26 次
- COLE: A Column-based Learned Storage for Blockchain SystemsCe Zhang, Cheng Xu, Haibo Hu, Jianliang XuFAST 2024 · 被引用 20 次
- CaaS-LSM: Compaction-as-a-Service for LSM-based Key-Value Stores in Storage Disaggregated InfrastructureQiaolin Yu, Chang Guo, Jay Zhuang, Viraj Thakkar 等SIGMOD 2024 · 被引用 18 次
- GRF: A Global Range Filter for LSM-Trees with Shape EncodingHengrui Wang, Te Guo, Junzhao Yang, Huanchen ZhangSIGMOD 2024 · 被引用 15 次
- CAMAL: Optimizing LSM-trees via Active LearningWeiping Yu, Siqiang Luo, Zihao Yu, Gao CongSIGMOD 2025 · 被引用 11 次
它引用的顶会 Paper13
- ZNS: Avoiding the Block Interface Tax for Flash-based SSDsMatias Bjørling, Abutalib Aghayev, Hans Holmberg, Aravind Ramesh 等USENIX ATC 2021 · 被引用 221 次
- MatrixKV: Reducing Write Stalls and Write Amplification in LSM-tree Based KV Stores with Matrix Container in NVMTing Yao, Yiwen Zhang, Jiguang Wan, Qiu Cui 等USENIX ATC 2020 · 被引用 186 次
- From WiscKey to Bourbon: A Learned Index for Log-Structured Merge TreesYifan Dai, Yien Xu, Aishwarya Ganesan, Ramnatthan Alagappan 等OSDI 2020 · 被引用 138 次
- Evolution of Development Priorities in Key-value Stores Serving Large-scale Applications: The RocksDB ExperienceSiying Dong, Andrew Kryczka, Yanqin Jin, Michael StummFAST 2021 · 被引用 110 次
- FPGA-Accelerated Compactions for LSM-based Key-Value StoreTeng Zhang, Jianying Wang, Xuntao Cheng, Hao Xu 等FAST 2020 · 被引用 99 次
相关 Paper
- Reducing Write Amplification of LSM-Tree with Block-Grained CompactionXiaoliang Wang, Peiquan Jin, Bei Hua, Hai Long 等ICDE 2022 · 被引用 26 次
- Scavenger: Better Space-Time Trade-Offs for Key-Value Separated LSM-treesJianshun Zhang, Fang Wang, Sheng Qiu, Yi Wang 等ICDE 2024 · 被引用 5 次
- Constructing and Analyzing the LSM Compaction Design SpaceSubhadeep Sarkar, Dimitris Staratzis, Zichen Zhu, Manos AthanassoulisVLDB 2021 · 被引用 73 次
- gParaKV: A GPGPU-accelerated Key-Value Separation-based KV Store with Optimized Compaction and Garbage CollectionHui Sun, Xiangxiang Jiang, Xiao Qin, Song Jiang 等SC 2025 · 被引用 3 次
- PartitionKV: Redesigning LSM-tree KV Stores on NVMs with Adaptive Partitioning for Reducing Write Stalls and AmplificationXingye Huang, Jinyu Wu, Xiaofang Xia, Jiangtao Cui 等SIGMOD 2026
