add method to get checkpoint_seq from WAL

This commit is contained in:
Nikita Sivukhin
2025-08-21 15:07:03 +04:00
parent 38eb5232c8
commit 25cb28da67

View File

@@ -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
}