Skip to content

Commit b157714

Browse files
authored
Merge pull request #304445 from MicrosoftDocs/main
8/20/2025 11:00 AM IST Publish
2 parents def1706 + 122df02 commit b157714

2 files changed

Lines changed: 53 additions & 5 deletions

File tree

articles/azure-app-configuration/configuration-provider-overview.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,10 @@ Dynamic Refresh (Poll Mode) | [GA](./reference-dotnet-provider.md#refresh-on-sen
5454
Dynamic Refresh (Push Mode) | GA | GA | N/A | N/A | N/A | N/A
5555
Dynamic Refresh (Collection Monitoring) | [GA](./reference-dotnet-provider.md#configuration-refresh) | WIP | GA | WIP | [GA](./reference-javascript-provider.md#configuration-refresh) | GA
5656
JSON Content Type Handling | [GA](./reference-dotnet-provider.md#json-content-type-handling) | GA | GA | GA | [GA](./reference-javascript-provider.md#json-content-type-handling) | GA
57+
JSON with Comments | WIP | WIP | WIP | WIP | [GA](./reference-javascript-provider.md#json-content-type-handling) | WIP
5758
Configuration Setting Mapping | [GA](./reference-dotnet-provider.md#configuration-setting-mapping) | N/A | N/A | N/A | N/A | N/A
5859
Key Vault References | [GA](./reference-dotnet-provider.md#key-vault-reference) | GA | GA | GA | [GA](./reference-javascript-provider.md#key-vault-reference) | GA
59-
Key Vault Secret Refresh | [GA](./reference-dotnet-provider.md#key-vault-secret-refresh) | N/A | GA | WIP | WIP | GA
60+
Key Vault Secret Refresh | [GA](./reference-dotnet-provider.md#key-vault-secret-refresh) | WIP | GA | WIP | [GA](./reference-javascript-provider.md#key-vault-secret-refresh) | GA
6061
Custom Key Vault Secret Resolution | [GA](./reference-dotnet-provider.md#key-vault-reference) | GA | GA | GA | [GA](./reference-javascript-provider.md#key-vault-reference) | GA
6162
Parallel Secret Resolution | WIP | N/A | WIP | N/A | [GA](./reference-javascript-provider.md#parallel-secret-resolution) | GA
6263
Feature Flags | [GA](./reference-dotnet-provider.md#feature-flag) | GA | GA | GA | [GA](./reference-javascript-provider.md#feature-flag) | GA
@@ -69,8 +70,8 @@ Replica Failover | [GA](./reference-dotnet-provider.md#geo-replication) | GA | G
6970
Replica Load Balancing | [GA](./reference-dotnet-provider.md#geo-replication) | WIP | GA | GA | [GA](./reference-javascript-provider.md#geo-replication) | WIP
7071
Snapshots | [GA](./reference-dotnet-provider.md#snapshot) | GA | GA | WIP | [GA](./reference-javascript-provider.md#snapshot) | WIP
7172
Distributed Tracing | [GA](./reference-dotnet-provider.md#distributed-tracing) | WIP | WIP | WIP | WIP | WIP
72-
Health Check | [GA](./reference-dotnet-provider.md#health-check) | WIP | WIP | WIP | WIP | WIP
73-
Select by Tag Filters | [GA](./reference-dotnet-provider.md#load-specific-key-values-using-selectors) | WIP | WIP | GA | WIP | WIP
73+
Health Check | [GA](./reference-dotnet-provider.md#health-check) | GA | WIP | WIP | WIP | WIP
74+
Select by Tag Filters | [GA](./reference-dotnet-provider.md#load-specific-key-values-using-selectors) | WIP | WIP | GA | [GA](./reference-javascript-provider.md#tag-filters) | WIP
7475

7576
## Support policy
7677

articles/azure-app-configuration/reference-javascript-provider.md

Lines changed: 49 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,9 @@ const appConfig = await load(endpoint, credential);
138138
const { size, color } = appConfig.get("font");
139139
```
140140

141+
> [!NOTE]
142+
> Starting with version *2.2.0* of `@azure/app-configuration-provider`, the configuration provider can properly recognize JSON with comments([JSONC](https://jsonc.org/)) and convert it into object.
143+
141144
### Load specific key-values using selectors
142145

143146
By default, the `load` method will load all configurations with no label from the configuration store. You can configure the behavior of the `load` method through the optional parameter of [`AzureAppConfigurationOptions`](https://github.com/Azure/AppConfiguration-JavaScriptProvider/blob/main/src/AzureAppConfigurationOptions.ts) type.
@@ -151,8 +154,9 @@ const appConfig = await load(endpoint, credential, {
151154
keyFilter: "app1.*",
152155
labelFilter: "test"
153156
},
154-
{ // load the subset of keys starting with "dev" label"
155-
labelFilter: "dev*"
157+
{ // load the subset of keys with "dev" label"
158+
keyFilter: "*",
159+
labelFilter: "dev"
156160
}
157161
]
158162
});
@@ -161,6 +165,29 @@ const appConfig = await load(endpoint, credential, {
161165
> [!NOTE]
162166
> Key-values are loaded in the order in which the selectors are listed. If multiple selectors retrieve key-values with the same key, the value from the last one will override any previously loaded value.
163167

168+
#### Tag filters
169+
170+
The tag filters parameter selects key-values with specific tags. A key-value is only loaded if it has all of the tags and corresponding values specified in the filters.
171+
172+
```typescript
173+
const appConfig = await load(endpoint, credential, {
174+
selectors: [
175+
{ // load the subset of keys with "test" label" and three tags
176+
keyFilter: "*",
177+
labelFilter: "test",
178+
tagFilters: [
179+
"emptyTag=",
180+
"nullTag=\0",
181+
"tag1=value1"
182+
]
183+
}
184+
]
185+
});
186+
```
187+
188+
> [!NOTE]
189+
> The characters asterisk (`*`), comma (`,`), and backslash (`\`) are reserved and must be escaped with a backslash when used in a tag filter.
190+
164191
### Trim prefix from keys
165192
166193
You can trim the prefix off of keys by providing a list of trimmed key prefixes to the `AzureAppConfigurationOptions.trimKeyPrefixes` property.
@@ -391,6 +418,26 @@ const appConfig = await load(endpoint, credential, {
391418
> When resolving secret in parallel, you may encounter the [service limit](/azure/key-vault/general/service-limits#secrets-managed-storage-account-keys-and-vault-transactions) of Azure Key Vault.
392419
> To handle throttling effectively, implement the [client-side throttling best practices](/azure/key-vault/general/overview-throttling#how-to-throttle-your-app-in-response-to-service-limits) by configuring appropriate retry options for the `SecretClient`. You can either register custom `SecretClient` instances or configure `clientOptions` via the `AzureAppConfigurationOptions.keyVaultOptions`.
393420
421+
### Key Vault secret refresh
422+
423+
Azure App Configuration enables you to configure secret refresh intervals independently of your configuration refresh cycle. This is crucial for security because while the Key Vault reference URI in App Configuration remains unchanged, the underlying secret in Key Vault might be rotated as part of your security practices.
424+
425+
To ensure your application always uses the most current secret values, configure the `secretRefreshIntervalInMs` property in `KeyVaultOptions`. This forces the provider to retrieve fresh secret values from Key Vault when:
426+
427+
- Your application calls `AzureAppConfiguration.refresh`
428+
- The configured refresh interval for the secret has elapsed
429+
430+
This mechanism works even when no changes are detected in your App Configuration store, ensuring your application stays in sync with rotated secrets.
431+
432+
```typescript
433+
const credential = new DefaultAzureCredential();
434+
const appConfig = await load(endpoint, credential, {
435+
keyVaultOptions: {
436+
credential: credential,
437+
secretRefreshIntervalInMs: 7200_000 // 2 hours
438+
}
439+
});
440+
```
394441
395442
## Snapshot
396443

0 commit comments

Comments
 (0)