refactor: stabilize heal format recovery integration tests (#1984)

Co-authored-by: houseme <housemecn@gmail.com>
This commit is contained in:
安正超
2026-02-27 15:26:19 +08:00
committed by GitHub
parent 3433dfa88e
commit 9d2b8822cf
26 changed files with 849 additions and 125 deletions
+8 -1
View File
@@ -20,6 +20,7 @@ use crate::heal::{
use crate::{Error, Result};
use rustfs_common::heal_channel::{
HealChannelCommand, HealChannelPriority, HealChannelReceiver, HealChannelRequest, HealChannelResponse, HealScanMode,
publish_heal_response,
};
use std::sync::Arc;
use tokio::sync::mpsc;
@@ -226,9 +227,15 @@ impl HealChannelProcessor {
}
fn publish_response(&self, response: HealChannelResponse) {
if let Err(e) = self.response_sender.send(response) {
// Try to send to local channel first, but don't block broadcast on failure
if let Err(e) = self.response_sender.send(response.clone()) {
error!("Failed to enqueue heal response locally: {}", e);
}
// Always attempt to broadcast, even if local send failed
// Use the original response for broadcast; local send uses a clone
if let Err(e) = publish_heal_response(response) {
error!("Failed to broadcast heal response: {}", e);
}
}
/// Get response sender for external use