16 unstable releases (4 breaking)

new 0.5.2 Sep 18, 2020
0.5.1 Aug 25, 2020
0.4.0 Jul 30, 2020
0.3.0 Mar 2, 2020
0.2.0 Nov 28, 2019

#43 in Filesystem

Download history 37/week @ 2020-06-01 9/week @ 2020-06-08 12/week @ 2020-06-15 14/week @ 2020-06-22 9/week @ 2020-06-29 17/week @ 2020-07-06 21/week @ 2020-07-13 12/week @ 2020-07-20 25/week @ 2020-07-27 3/week @ 2020-08-03 20/week @ 2020-08-10 34/week @ 2020-08-17 32/week @ 2020-08-24 22/week @ 2020-08-31 71/week @ 2020-09-07 33/week @ 2020-09-14

99 downloads per month

MIT and GPL-3.0 licenses

99KB
2.5K SLoC

Pearl

Build Status Crate Status Docs Status

Append only key-value blob storage on disk

Table of Contents

Overview

Storage scheme

pearl storage scheme

Blob

Header

Structure:

struct Header {
    magic_byte: u64,
    version: u32,
    flags: u64,
}

Description

Field Size, B Description
magic_byte 8 marks pearl blob
version any used to check compatibility
flags 1 additional file props

Record

Header

Structure:

pub struct Header {
    magic_byte: u64,
    key: Vec<u8>,
    meta_size: u64,
    data_size: u64,
    flags: u8,
    blob_offset: u64,
    created: u64,
    data_checksum: u32,
    header_checksum: u32,
}

Description

Field Size, B Description
magic_byte 8 separates records in blob
key (any) key for record location and searching
meta_size 8 meta length
data_size 8 data length (without header)
flags 1 additional record metadata
blob_offset 8 record offset from blob start
created 8 created timestamp
data_checksum 4 data crc32 checksum (without header)
header_checksum 4 header crc32 checksum (only record header)

Rust Version

pearl works on stable rust and above

$ rustup update
$ cargo build

Dependencies

~8MB
~165K SLoC