Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

azureblob: fix errors not being retried when doing single part copy

Nick Craig-Woodb7f26937f148
diff --git a/backend/azureblob/azureblob.go b/backend/azureblob/azureblob.go
index c2db11267..4c7f2791e 100644
--- a/backend/azureblob/azureblob.go
+++ b/backend/azureblob/azureblob.go
@@ -1888,7 +1888,11 @@ func (f *Fs) copySinglepart(ctx context.Context, remote, dstContainer, dstPath s
pollTime := 100 * time.Millisecond
for copyStatus != nil && string(*copyStatus) == string(container.CopyStatusTypePending) {
time.Sleep(pollTime)
- getMetadata, err := dstBlobSVC.GetProperties(ctx, &getOptions)
+ var getMetadata blob.GetPropertiesResponse
+ err = f.pacer.Call(func() (bool, error) {
+ getMetadata, err = dstBlobSVC.GetProperties(ctx, &getOptions)
+ return f.shouldRetry(ctx, err)
+ })
if err != nil {
return nil, err
}