KV 数据库
KV 存储引擎知识体系 —— 按存储模型分类整理 RocksDB / LevelDB / Pebble / Badger / LMDB / redb / bbolt,以及 Bitcask 模型(rosedb / basho/bitcask)的机制 与选型。
存储模型分类
| 模型 | 代表引擎 | 核心思路 |
| LSM-Tree | RocksDB / LevelDB / Pebble / Badger | 顺序写 + 分层 compaction,写密集首选;key 索引不必全放内存 |
| B+Tree | LMDB / redb / bbolt | 原地更新 + mmap,读密集 / 低内存 |
| Bitcask(日志 + 内存索引) | rosedb / basho/bitcask | append-only 日志 + 全部 key 的 keydir 常驻内存,读最多一次 seek,靠 merge 回收空间 |
Docs
| Docs | Description |
| KV 数据库对比 | KV 引擎全面对比(语言、存储结构、性能、生态) |
| Bitcask 存储模型 | 日志结构哈希表:数据结构(entry / keydir / hint file / merge)、读写路径、优劣与实现列表 |
Backlinks (1)
flowchart LR
n0["Collection"]
n1["Maps"]
n2["CRC(循环冗余校验)原理"]
n3["Algorithms"]
n4["Database"]
n5["Bitcask 存储模型(日志结构哈希表)"]
n6["KV 数据库对比"]
n7["KV 数据库"]
n8["PostgreSQL 活跃会话诊断(Active Sessions)"]
n9["PostgreSQL 磁盘占用查看(Table Size / Datafile)"]
n10["PostgreSQL"]
n11["PostgreSQL 内存占用查看(Memory / Buffers / Connections)"]
n12["PostgreSQL 查看慢查询(Slow Query)"]
n13["PostgreSQL WAL 与 LSN"]
n14["Knowledge"]
n15["Cloud"]
n16["对象存储基本用法(Bucket / Object / 常用操作)"]
n17["对象存储数据迁移(R2 → MinIO / 跨厂商搬迁)"]
n18["Object Storage"]
n19["挂载 Bucket 为本地文件系统(FUSE Mount)"]
n20["对象存储签名 URL(Signed URL)原理与实战"]
n21["对象存储供应商对比(S3 / R2 / OSS / Supabase / MinIO)"]
n22["Infrastructure"]
n23["Prototypes"]
n24["Research"]
n25["Better Auth 源码阅读指南"]
n26["DuckDB 实战研究"]
n27["英语学习 Dashboard"]
n28["Jellyfin 源码阅读指南"]
n29["Lux 资料整理"]
n30["Nest Commander 学习资料"]
n31["NestJS 源码阅读指南"]
n32["Protomaps 自建底图研究"]
n33["自制 PMTiles 地图(最简单例子)"]
n34["MapLibre 集成 Protomaps"]
n35["PMTiles 格式与工具链"]
n36["上海地区底图项目"]
n37["Redash 源码阅读指南"]
n38["shadcn/ui 实用研究(从环境到基本使用)"]
n39["TRIP 项目核心原理与代码阅读指南"]
n0 --> n1
n0 --> n24
n3 --> n2
n4 --> n7
n4 --> n10
n6 --> n5
n7 --> n5
n7 --> n6
n10 --> n8
n10 --> n9
n10 --> n11
n10 --> n12
n10 --> n13
n11 --> n8
n11 --> n9
n12 --> n8
n14 --> n3
n14 --> n4
n14 --> n22
n15 --> n18
n16 --> n17
n16 --> n20
n16 --> n21
n16 --> n23
n17 --> n16
n17 --> n19
n17 --> n20
n17 --> n21
n18 --> n16
n18 --> n17
n18 --> n19
n18 --> n20
n18 --> n21
n19 --> n16
n19 --> n20
n19 --> n21
n20 --> n23
n21 --> n16
n21 --> n17
n21 --> n20
n21 --> n23
n22 --> n15
n23 --> n5
n23 --> n16
n23 --> n19
n23 --> n20
n23 --> n21
n23 --> n32
n24 --> n25
n24 --> n26
n24 --> n27
n24 --> n28
n24 --> n29
n24 --> n30
n24 --> n31
n24 --> n32
n24 --> n37
n24 --> n38
n24 --> n39
n26 --> n24
n32 --> n1
n32 --> n33
n32 --> n34
n32 --> n35
n32 --> n36
n33 --> n35
n34 --> n23
n34 --> n36
n35 --> n33
n35 --> n36
n36 --> n34
n36 --> n35
n38 --> n24
click n0 "../../../collection/" "Collection"
click n1 "../../../collection/maps/" "Maps"
click n2 "../../algorithms/crc/" "CRC(循环冗余校验)原理"
click n3 "../../algorithms/" "Algorithms"
click n4 "../" "Database"
click n5 "bitcask/" "Bitcask 存储模型(日志结构哈希表)"
click n6 "comparison/" "KV 数据库对比"
click n7 "./" "KV 数据库"
click n8 "../postgresql/active-sessions/" "PostgreSQL 活跃会话诊断(Active Sessions)"
click n9 "../postgresql/disk-usage/" "PostgreSQL 磁盘占用查看(Table Size / Datafile)"
click n10 "../postgresql/" "PostgreSQL"
click n11 "../postgresql/memory-usage/" "PostgreSQL 内存占用查看(Memory / Buffers / Connections)"
click n12 "../postgresql/slow-queries/" "PostgreSQL 查看慢查询(Slow Query)"
click n13 "../postgresql/wal-lsn/" "PostgreSQL WAL 与 LSN"
click n14 "../../" "Knowledge"
click n15 "../../infrastructure/cloud/" "Cloud"
click n16 "../../infrastructure/cloud/object-storage/basic-usage/" "对象存储基本用法(Bucket / Object / 常用操作)"
click n17 "../../infrastructure/cloud/object-storage/data-migration/" "对象存储数据迁移(R2 → MinIO / 跨厂商搬迁)"
click n18 "../../infrastructure/cloud/object-storage/" "Object Storage"
click n19 "../../infrastructure/cloud/object-storage/mount-bucket/" "挂载 Bucket 为本地文件系统(FUSE Mount)"
click n20 "../../infrastructure/cloud/object-storage/signed-url/" "对象存储签名 URL(Signed URL)原理与实战"
click n21 "../../infrastructure/cloud/object-storage/vendors-comparison/" "对象存储供应商对比(S3 / R2 / OSS / Supabase / MinIO)"
click n22 "../../infrastructure/" "Infrastructure"
click n23 "../../../prototypes/" "Prototypes"
click n24 "../../../research/" "Research"
click n25 "../../../research/topics/better-auth/" "Better Auth 源码阅读指南"
click n26 "../../../research/topics/duckdb/" "DuckDB 实战研究"
click n27 "../../../research/topics/english/" "英语学习 Dashboard"
click n28 "../../../research/topics/jellyfin/" "Jellyfin 源码阅读指南"
click n29 "../../../research/topics/lux/" "Lux 资料整理"
click n30 "../../../research/topics/nest-commander/" "Nest Commander 学习资料"
click n31 "../../../research/topics/nestjs/" "NestJS 源码阅读指南"
click n32 "../../../research/topics/protomaps/" "Protomaps 自建底图研究"
click n33 "../../../research/topics/protomaps/make-own-map/" "自制 PMTiles 地图(最简单例子)"
click n34 "../../../research/topics/protomaps/maplibre/" "MapLibre 集成 Protomaps"
click n35 "../../../research/topics/protomaps/pmtiles/" "PMTiles 格式与工具链"
click n36 "../../../research/topics/protomaps/shanghai-map/" "上海地区底图项目"
click n37 "../../../research/topics/redash/" "Redash 源码阅读指南"
click n38 "../../../research/topics/shadcn-ui/" "shadcn/ui 实用研究(从环境到基本使用)"
click n39 "../../../research/topics/trip/" "TRIP 项目核心原理与代码阅读指南"
Links (2)