Chris Lu
1 day ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
2 additions and
2 deletions
-
weed/mount/metadata_flush_retry.go
|
|
|
@ -12,10 +12,10 @@ func retryMetadataFlush(flush func() error, onRetry func(nextAttempt, totalAttem |
|
|
|
for attempt := 1; attempt <= totalAttempts; attempt++ { |
|
|
|
err = flush() |
|
|
|
if err == nil { |
|
|
|
return nil |
|
|
|
break |
|
|
|
} |
|
|
|
if attempt == totalAttempts { |
|
|
|
return err |
|
|
|
break |
|
|
|
} |
|
|
|
|
|
|
|
backoff := time.Duration(1<<uint(attempt-1)) * time.Second |
|
|
|
|