mirror of
https://github.com/aljazceru/turso.git
synced 2026-02-12 03:34:20 +01:00
add method to get checkpoint_seq from WAL
This commit is contained in:
@@ -289,6 +289,7 @@ pub trait Wal: Debug {
|
||||
fn sync(&mut self) -> Result<Completion>;
|
||||
fn is_syncing(&self) -> bool;
|
||||
fn get_max_frame_in_wal(&self) -> u64;
|
||||
fn get_checkpoint_seq(&self) -> u32;
|
||||
fn get_max_frame(&self) -> u64;
|
||||
fn get_min_frame(&self) -> u64;
|
||||
fn rollback(&mut self) -> Result<()>;
|
||||
@@ -1303,6 +1304,10 @@ impl Wal for WalFile {
|
||||
self.get_shared().max_frame.load(Ordering::Acquire)
|
||||
}
|
||||
|
||||
fn get_checkpoint_seq(&self) -> u32 {
|
||||
self.header.checkpoint_seq
|
||||
}
|
||||
|
||||
fn get_max_frame(&self) -> u64 {
|
||||
self.max_frame
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user