MCPcopy
hub / github.com/borgbackup/borg / chunk_processor

Method chunk_processor

src/borg/archive.py:1212–1218  ·  view source on GitHub ↗
(chunk)

Source from the content-addressed store, hash-verified

1210 if not chunk_processor:
1211
1212 def chunk_processor(chunk):
1213 started_hashing = time.monotonic()
1214 chunk_id, data = cached_hash(chunk, self.key.id_hash)
1215 stats.hashing_time += time.monotonic() - started_hashing
1216 chunk_entry = cache.add_chunk(chunk_id, {}, data, stats=stats, wait=False, ro_type=ROBJ_FILE_STREAM)
1217 self.cache.repository.async_response(wait=False)
1218 return chunk_entry
1219
1220 item.chunks = []
1221 for chunk in chunk_iter:

Callers

nothing calls this directly

Calls 3

cached_hashFunction · 0.85
add_chunkMethod · 0.45
async_responseMethod · 0.45

Tested by

no test coverage detected