Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Info

Details in Retry pattern - Azure Architecture Center | Microsoft Learn

Problem

Solution

Retry In Practice

Info

Code & Explanation : Implement a retry policy using the Azure Storage client library for .NET - Azure Storage | Microsoft Learn

Code Block
languagec#
// Provide the client configuration options for connecting to Azure Blob Storage
BlobClientOptions blobOptions = new BlobClientOptions()
{
    Retry = {
        Delay = TimeSpan.FromSeconds(2),
        MaxRetries = 5,
        Mode = RetryMode.Exponential,
        MaxDelay = TimeSpan.FromSeconds(10),
        NetworkTimeout = TimeSpan.FromSeconds(100)
    },
};
BlobServiceClient blobServiceClient = new BlobServiceClient(accountUri, new DefaultAzureCredential(), blobOptions);