bitcask-kv: مخزن key/value مبني على الـ log بلغة Rust، من الورقة العلمية
مخزن المفتاح/القيمة (key/value store) يبدو أبسط قاعدة بيانات ممكنة: put و get و delete . الصعوبة ليست في الـ API. الصعوبة فيما يحدث حين تنقطع الكهرباء في منتصف كتابة، وحين تكبر ملفات البيانات بلا نهاية لأن القيم القديمة لا تُستردّ مساحتها، وحين يُعاد تشغيل البرنامج وعليه أن يجد كل مفتاح من جديد. ورقة Bitcask، المكتوبة لقاعدة البيانات Riak، تجيب عن الثلاثة بفكرة واحدة: لا تعدّل البيانات في مكانها…
Bitcask-kv is a key/value store built on a log, written in Rust, and inspired by the Bitcask paper for the Riak database. The simplicity of its API lies in its put, get, and delete functions. The real challenge comes from handling write failures, ever-growing data files that never reclaim space, and the need to rebuild each key from scratch after a restart.
Bitcask answers these challenges by never modifying data in place, instead appending logs and maintaining an in-memory index. The paper is concise, making it an accessible starting point for storage experiments. Bitcask-kv is a Rust implementation featuring append-only files, a memory-based hash index, merge/compaction, fast startup via hint files, and recovery from corrupted writes. These features constitute the core of the system.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.
This story
This is one outlet's version. Read the fullest account.