MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / sync

Method sync

nodedb/src/wal/audit_segment.rs:76–81  ·  view source on GitHub ↗

Sync the audit WAL to disk (fsync).

(&self)

Source from the content-addressed store, hash-verified

74
75 /// Sync the audit WAL to disk (fsync).
76 pub fn sync(&self) -> crate::Result<()> {
77 let mut wal = self.wal.lock().map_err(|_| crate::Error::Internal {
78 detail: "audit WAL lock poisoned".into(),
79 })?;
80 wal.sync().map_err(crate::Error::Wal)
81 }
82
83 /// Append AND sync atomically. This is the primary durable write path.
84 pub fn append_durable(&self, audit_bytes: &[u8], data_lsn: u64) -> crate::Result<u64> {

Callers 1

append_durableMethod · 0.45

Calls 1

lockMethod · 0.80

Tested by

no test coverage detected