heal: Avoid marking a bucket as done when remote drives are offline (#19587)

This commit is contained in:
Anis Eleuch
2024-04-26 07:32:14 +01:00
committed by GitHub
parent f4f1c42cba
commit 135874ebdc
4 changed files with 24 additions and 22 deletions

View File

@@ -44,8 +44,8 @@ const (
healingMetricCheckAbandonedParts
)
func (er erasureObjects) listAndHeal(bucket, prefix string, scanMode madmin.HealScanMode, healEntry func(string, metaCacheEntry, madmin.HealScanMode) error) error {
ctx, cancel := context.WithCancel(context.Background())
func (er erasureObjects) listAndHeal(ctx context.Context, bucket, prefix string, scanMode madmin.HealScanMode, healEntry func(string, metaCacheEntry, madmin.HealScanMode) error) error {
ctx, cancel := context.WithCancel(ctx)
defer cancel()
disks, _ := er.getOnlineDisksWithHealing(false)