diff --git a/sdk/azidentity/CHANGELOG.md b/sdk/azidentity/CHANGELOG.md index 4b2166a87974..213de2b6f972 100644 --- a/sdk/azidentity/CHANGELOG.md +++ b/sdk/azidentity/CHANGELOG.md @@ -13,6 +13,8 @@ ### Bugs Fixed ### Other Changes +- By default, `ManagedIdentityCredential` retries IMDS requests for a maximum of ~70 seconds as recommended + in IMDS documentation. In previous versions, it would stop retrying after ~54 seconds by default. ## 1.10.1 (2025-06-10) diff --git a/sdk/azidentity/managed_identity_client.go b/sdk/azidentity/managed_identity_client.go index b3a0f85883fa..0735d1fcbef4 100644 --- a/sdk/azidentity/managed_identity_client.go +++ b/sdk/azidentity/managed_identity_client.go @@ -54,10 +54,10 @@ type managedIdentityClient struct { // setIMDSRetryOptionDefaults sets zero-valued fields to default values appropriate for IMDS func setIMDSRetryOptionDefaults(o *policy.RetryOptions) { if o.MaxRetries == 0 { - o.MaxRetries = 5 + o.MaxRetries = 6 } if o.MaxRetryDelay == 0 { - o.MaxRetryDelay = 1 * time.Minute + o.MaxRetryDelay = 25 * time.Second } if o.RetryDelay == 0 { o.RetryDelay = 2 * time.Second