Skip to content

Add AddAppConfigurations extension for config-section-based client construction#728

Open
m-nash wants to merge 1 commit intoAzure:mainfrom
m-nash:add-app-configurations-extension
Open

Add AddAppConfigurations extension for config-section-based client construction#728
m-nash wants to merge 1 commit intoAzure:mainfrom
m-nash:add-app-configurations-extension

Conversation

@m-nash
Copy link
Member

@m-nash m-nash commented Mar 4, 2026

Summary

Adds two new AddAppConfigurations extension methods on IConfigurationBuilder that allow constructing an Azure App Configuration provider directly from an IConfiguration section using the new ConfigurationClientSettings from Azure.Data.AppConfiguration 1.9.0 and GetAzureClientSettings<T> from Azure.Identity 1.18.0.

This replaces the approach taken in Azure/azure-sdk-for-net#56619 (which created a separate package) by implementing the functionality directly in the existing provider package.

Resolves Azure/azure-sdk-for-net#55509

Changes

New APIs (marked [Experimental("SCME0002")])

  • AddAppConfigurations(IConfigurationBuilder, string, bool) - Adds App Configuration using a named configuration section
  • AddAppConfigurations(IConfigurationBuilder, string, Action<AzureAppConfigurationOptions>, bool) - Same with additional options callback

Package Updates

  • Azure.Data.AppConfiguration 1.8.0 -> 1.9.0 (provides ConfigurationClientSettings)
  • Azure.Identity 1.15.0 -> 1.18.0 (provides GetAzureClientSettings<T>)
  • Microsoft.Extensions.DependencyInjection.Abstractions 8.0.2 -> 10.0.3 (required by transitive deps)

New Files

  • ExperimentalAttribute.cs - Polyfill for [Experimental] attribute on netstandard2.0/2.1
  • docs/ExperimentalFeatures.md - Documents the SCME0002 diagnostic ID usage
  • ConfigurationSettingsTests.cs - 10 unit tests (6 validation + 4 happy-path)

Example Usage

var config = new ConfigurationBuilder()
    .AddJsonFile("appsettings.json")
    .AddAppConfigurations("AppConfiguration")
    .Build();

…nstruction

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Microsoft.Extensions.Configuration.Azure.AppConfiguration: Add IConfigurationSource Extension

1 participant