MCPcopy
hub / github.com/saltstack/salt / _segment_path

Method _segment_path

salt/utils/mmap_cache.py:268–272  ·  view source on GitHub ↗

Return the filesystem path for heap segment *seg_id*.

(self, seg_id)

Source from the content-addressed store, hash-verified

266 # ------------------------------------------------------------------
267
268 def _segment_path(self, seg_id):
269 """Return the filesystem path for heap segment *seg_id*."""
270 if seg_id == 0:
271 return self.heap_path
272 return f"{self.heap_path}.{seg_id}"
273
274 def _active_segment_id(self):
275 """Return the ID of the segment that should receive the next append."""

Callers 11

_discover_segmentsMethod · 0.95
_open_heap_mmapMethod · 0.95
_append_to_heapMethod · 0.95
_read_from_heapMethod · 0.95
_overwrite_in_heapMethod · 0.95
atomic_rebuildMethod · 0.95
seg_pathFunction · 0.80
test_seg1_pathMethod · 0.80
test_seg100_pathMethod · 0.80

Calls

no outgoing calls

Tested by 4

seg_pathFunction · 0.64
test_seg1_pathMethod · 0.64
test_seg100_pathMethod · 0.64