#persistence #lsm-tree #embedded

emerald-rocksdb

Rust wrapper for Facebook's RocksDB embeddable database used in Emerald project

5 releases (3 major breaking)

Uses old Rust 2015

100.0.0 Jan 30, 2018
2.8.2 Jan 25, 2018
1.8.2 Jan 24, 2018
1.0.0 Oct 25, 2017
0.10.0 Oct 26, 2017

#2149 in Database interfaces

Download history 8/week @ 2024-09-18 6/week @ 2024-09-25

51 downloads per month
Used in 5 crates (3 directly)

Apache-2.0

105KB
2K SLoC

emerald-rocksdb

Build Status Build status documentation

This binding is statically linked with a specific version of RocksDB. If you want to build it yourself, make sure you've also cloned the RocksDB and Snappy submodules:

git submodule update --init --recursive

lib.rs:

Rust wrapper for RocksDB.

Examples

 use emerald_rocksdb::DB;
 // NB: db is automatically closed at end of lifetime
 let db = DB::open_default("path/for/rocksdb/storage").unwrap();
 db.put(b"my key", b"my value");
 match db.get(b"my key") {
    Ok(Some(value)) => println!("retrieved value {}", value.to_utf8().unwrap()),
    Ok(None) => println!("value not found"),
    Err(e) => println!("operational problem encountered: {}", e),
 }
 db.delete(b"my key").unwrap();

Dependencies

~26MB
~525K SLoC