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

Function stamp_put_cells

nodedb/src/engine/array/write.rs:92–113  ·  view source on GitHub ↗

Shared memtable-stamping core for puts. Recovery routes through here directly so write ordering is identical to the live dispatch path.

(
    store: &mut ArrayStore,
    cells: Vec<ArrayPutCell>,
    lsn: u64,
)

Source from the content-addressed store, hash-verified

90/// Shared memtable-stamping core for puts. Recovery routes through here
91/// directly so write ordering is identical to the live dispatch path.
92pub(crate) fn stamp_put_cells(
93 store: &mut ArrayStore,
94 cells: Vec<ArrayPutCell>,
95 lsn: u64,
96) -> ArrayEngineResult<()> {
97 let schema = store.schema().clone();
98 for c in cells {
99 store.memtable.put_cell(
100 &schema,
101 super::memtable::PutCell {
102 coord: c.coord,
103 attrs: c.attrs,
104 surrogate: c.surrogate,
105 system_from_ms: c.system_from_ms,
106 valid_from_ms: c.valid_from_ms,
107 valid_until_ms: c.valid_until_ms,
108 lsn,
109 },
110 )?;
111 }
112 Ok(())
113}
114
115pub(crate) fn stamp_delete_cells(
116 store: &mut ArrayStore,

Callers 2

apply_recordMethod · 0.85
put_cellsMethod · 0.85

Calls 3

put_cellMethod · 0.80
cloneMethod · 0.45
schemaMethod · 0.45

Tested by

no test coverage detected