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

Function segment_id

nodedb-fts/src/lsm/compaction.rs:153–155  ·  view source on GitHub ↗

Generate a segment id (unscoped).

(segment_id: u64, level: u32)

Source from the content-addressed store, hash-verified

151
152/// Generate a segment id (unscoped).
153pub fn segment_id(segment_id: u64, level: u32) -> String {
154 format!("L{level}:{segment_id:016x}")
155}
156
157/// Parse the level from a segment id. Returns 0 if unparseable.
158pub fn parse_level(id: &str) -> u32 {

Callers 4

segment_id_formatFunction · 0.85
flush_memtableMethod · 0.85
write_l0_segmentsFunction · 0.85

Calls

no outgoing calls

Tested by 2

segment_id_formatFunction · 0.68
write_l0_segmentsFunction · 0.68