Skip to content

Commit 20cf379

Browse files
author
Jill Grant
authored
Merge pull request #263787 from zhiyuanliang-ms/zhiyuanliang/update-faq
Update FAQ for Azure App Configuration
2 parents cf28348 + 6c383db commit 20cf379

File tree

1 file changed

+10
-0
lines changed
  • articles/azure-app-configuration

1 file changed

+10
-0
lines changed

articles/azure-app-configuration/faq.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,16 @@ sections:
181181
182182
To select other labels and your Spring profile(s), you can use a label filter like `',${spring.profiles.active}'`, which will select all keys without a label and the ones matching your Spring profiles. The rightmost label(s) take priority when duplicate keys are found.
183183
184+
- question: How to enable feature management in Blazor applications or as scoped services in .NET applications?
185+
answer: |
186+
Starting with version 3.1.0, the `Microsoft.FeatureManagement` library allows running feature management services, including feature filters, as scoped services in dependency injection-based .NET applications. To take advantage of this feature, you can simply replace the `AddFeatureManagement` call in your code with `AddScopedFeatureManagement`, as shown in the following code snippet:
187+
188+
```C#
189+
services.AddScopedFeatureManagement();
190+
```
191+
192+
Feature filters can evaluate a feature flag based on the properties of an HTTP Request. This is usually performed by inspecting the `HttpContext` through the singleton `IHttpContextAccessor` [pattern](https://learn.microsoft.com/en-us/azure/azure-app-configuration/howto-targetingfilter-aspnet-core#update-the-web-application-code-to-use-targetingfilter). However, this pattern does not work for [Blazor server applications](https://learn.microsoft.com/en-us/aspnet/core/blazor/security/server/interactive-server-side-rendering?view=aspnetcore-7.0#ihttpcontextaccessorhttpcontext-in-razor-components) where scoped services should be used instead. In this case, `AddScopedFeatureManagement` method should be used.
193+
184194
- question: How can I receive announcements on new releases and other information related to App Configuration?
185195
answer: |
186196
Subscribe to our [GitHub announcements repo](https://github.com/Azure/AppConfiguration-Announcements).

0 commit comments

Comments
 (0)