Struct robt::Config[][src]

pub struct Config {
    pub dir: OsString,
    pub name: String,
    pub z_blocksize: usize,
    pub m_blocksize: usize,
    pub v_blocksize: usize,
    pub delta_ok: bool,
    pub value_in_vlog: bool,
    pub flush_queue_size: usize,
}

Configuration for Read Only BTree index.

Configuration type is used only for building an index. Subsequently, configuration parameters are persisted along with the index.

Fields

dir: OsString

location path where index files are created.

name: String

name of the index.

z_blocksize: usize

Leaf block size in btree index. Default: ZBLOCKSIZE

m_blocksize: usize

Intermediate block size in btree index. Default: MBLOCKSIZE

v_blocksize: usize

If deltas are indexed and/or value to be stored in separate log file. Default: VBLOCKSIZE

delta_ok: bool

Include delta as part of entry. Note that delta values are always stored in separate value-log file. Default: true

value_in_vlog: bool

If true, then value shall be persisted in a separate file called value log file. Otherwise value shall be saved in the index’s leaf node. Default: false

flush_queue_size: usize

Flush queue size. Default: FLUSH_QUEUE_SIZE

Implementations

impl Config[src]

pub fn new(dir: &OsStr, name: &str) -> Config[src]

Create a new configuration value, use the set_* methods to add more configuration.

pub fn set_blocksize(&mut self, z: usize, v: usize, m: usize) -> &mut Self[src]

Configure block size for leaf-node, intermediate-node, and value-log

pub fn set_delta(&mut self, delta_ok: bool) -> &mut Self[src]

Enable delta persistence. If delta_ok is false, older versions of value shall be ignored.

pub fn set_value_log(&mut self, value_log: bool) -> &mut Self[src]

Persist values in a separate file, called value-log file. To persist values along with leaf node, pass value_log as false.

pub fn set_flush_queue_size(&mut self, size: usize) -> &mut Self[src]

Set flush queue size, increasing the queue size will improve batch flushing.

impl Config[src]

Trait Implementations

impl Clone for Config[src]

impl Debug for Config[src]

impl From<Config> for Stats[src]

impl From<Stats> for Config[src]

Auto Trait Implementations

impl RefUnwindSafe for Config

impl Send for Config

impl Sync for Config

impl Unpin for Config

impl UnwindSafe for Config

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.