feat(ahm): add HealingTracker support & complete fresh-disk healing

• Introduce ecstore HealingTracker into ahm crate; load/init/save tracker
• Re-implement heal_fresh_disk to use heal_erasure_set with tracker
• Enhance auto-disk scanner: detect unformatted disks via get_disk_id()
• Remove DataUsageCache handling for now
• Refactor imports & types, clean up duplicate constants
This commit is contained in:
junxiang Mu
2025-07-11 18:42:12 +08:00
parent f4973a681c
commit 3409cd8dff
11 changed files with 731 additions and 515 deletions
+2 -4
View File
@@ -2757,8 +2757,8 @@ impl SetDisks {
false
}
};
for disk in out_dated_disks.iter() {
// write to all disks
for disk in self.disks.read().await.iter() {
let writer = create_bitrot_writer(
is_inline_buffer,
disk.as_ref(),
@@ -2821,7 +2821,6 @@ impl SetDisks {
// writers.push(None);
// }
}
// Heal each part. erasure.Heal() will write the healed
// part to .rustfs/tmp/uuid/ which needs to be renamed
// later to the final location.
@@ -2872,7 +2871,6 @@ impl SetDisks {
}
}
}
// Rename from tmp location to the actual location.
for (index, disk) in out_dated_disks.iter().enumerate() {
if let Some(disk) = disk {