mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-04-08 19:34:18 +00:00
consolidator: add progress to scan-old-directory passes
This commit is contained in:
parent
ddb2f1a6e3
commit
a18f8d4cc7
@ -144,7 +144,8 @@ class Consolidator:
|
||||
data = self.read_directory_json(archives_dircap)
|
||||
snapshots = {}
|
||||
|
||||
for (childname, (childtype, childdata)) in data["children"].items():
|
||||
children = sorted(data["children"].items())
|
||||
for i, (childname, (childtype, childdata)) in enumerate(children):
|
||||
if childtype != "dirnode":
|
||||
self.msg("non-dirnode %s in Archives/" % childname)
|
||||
continue
|
||||
@ -160,6 +161,8 @@ class Consolidator:
|
||||
if is_readonly:
|
||||
readcap = str(childdata["ro_uri"])
|
||||
if self.must_rescan_readonly_snapshots:
|
||||
self.msg(" scanning old %s (%d/%d)" %
|
||||
(childname, i+1, len(children)))
|
||||
self.scan_old_directory(str(childdata["ro_uri"]))
|
||||
snapshots[timestamp][2] = childname
|
||||
snapshots[timestamp][3] = readcap
|
||||
|
Loading…
x
Reference in New Issue
Block a user