Skip to content

Conversation

@christothes
Copy link
Member

Contributing to the Azure SDK

Please see our CONTRIBUTING.md if you are not familiar with contributing to this repository or have questions.

For specific information about pull request etiquette and best practices, see this section.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR implements a feature to disable probe requests and enable retries when ManagedIdentityCredential is explicitly configured via environment variables. The changes modify the DefaultAzureCredential behavior to skip the initial probe phase and allow exponential backoff retries when the credential chain is specifically configured to use ManagedIdentityCredential.

Key changes:

  • Modified factory methods to accept a probe control parameter
  • Added environment variable detection to disable probing when ManagedIdentityCredential is selected
  • Added comprehensive test coverage for the new behavior

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
DefaultAzureCredentialFactory.cs Modified CreateManagedIdentityCredential to accept probe control parameter and disable probing when called from environment variable configuration
TestDefaultAzureCredentialFactory.cs Updated method signature to match base class changes
MockDefaultAzureCredentialFactory.cs Updated method signature to match base class changes
ImdsManagedIdentityProbeSourceTests.cs Added comprehensive test cases to verify probing is disabled and retries are enabled when ManagedIdentityCredential is configured via environment variables
CHANGELOG.md Documented the new feature in the changelog

@christothes christothes enabled auto-merge (squash) September 9, 2025 20:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Development

Successfully merging this pull request may close these issues.

3 participants