Skip to main content

Wal

Trait Wal 

Source
pub trait Wal: Send {
    // Required methods
    fn log_commit_intent(&mut self, target_height: Height) -> Result<()>;
    fn log_commit_done(&mut self, target_height: Height) -> Result<()>;
}
Expand description

Write-Ahead Log trait for commit crash recovery.

Required Methods§

Source

fn log_commit_intent(&mut self, target_height: Height) -> Result<()>

Log intent to commit blocks up to target_height. Must fsync before returning.

Source

fn log_commit_done(&mut self, target_height: Height) -> Result<()>

Log that commit succeeded. May truncate the WAL.

Implementors§