Skip to content

Commit 320c961

Browse files
committed
Make changes to meet the minimum Acrolinx socre requirement.
1 parent 7f29135 commit 320c961

File tree

2 files changed

+23
-23
lines changed

2 files changed

+23
-23
lines changed

articles/azure-app-configuration/enable-dynamic-configuration-azure-kubernetes-service.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ ms.author: linglingye
1414

1515
# Tutorial: Use dynamic configuration in Azure Kubernetes Service
1616

17-
If you use Azure Kubernetes Service (AKS), this tutorial will show you how to enable dynamic configuration for your workloads in AKS by leveraging Azure App Configuration and its Kubernetes Provider. The tutorial assumes that you have already worked through the quickstart and have an App Configuration Kubernetes Provider set up, so before proceeding, make sure you have completed the [Use Azure App Configuration in Azure Kubernetes Service](./quickstart-azure-kubernetes-service.md) quickstart.
17+
If you use Azure Kubernetes Service (AKS), this tutorial shows you how to enable dynamic configuration for your workloads in AKS by leveraging Azure App Configuration and its Kubernetes Provider. The tutorial assumes that you work through the quickstart and have an App Configuration Kubernetes Provider set up, so before proceeding, make sure you complete the [Use Azure App Configuration in Azure Kubernetes Service](./quickstart-azure-kubernetes-service.md) quickstart.
1818

1919
> [!TIP]
2020
> See [options](./howto-best-practices.md#azure-kubernetes-service-access-to-app-configuration) for workloads hosted in Kubernetes to access Azure App Configuration.
@@ -38,7 +38,7 @@ Add the following key-value to your App Configuration store. For more informatio
3838

3939
## Reload data from App Configuration
4040

41-
1. Open the *appConfigurationProvider.yaml* file located in the *Deployment* directory. Then, add the `refresh` section under the `configuration` property as shown below. It enables configuration refresh by monitoring the sentinel key.
41+
1. Open the *appConfigurationProvider.yaml* file located in the *Deployment* directory. Then, add the `refresh` section under the `configuration` property. It enables configuration refresh by monitoring the sentinel key.
4242

4343
```yaml
4444
apiVersion: azconfig.io/v1
@@ -66,15 +66,15 @@ Add the following key-value to your App Configuration store. For more informatio
6666
> [!TIP]
6767
> By default, the Kubernetes provider polls the monitoring key-values every 30 seconds for change detection. However, you can change this behavior by setting the `interval` property of the `refresh`. If you want to reduce the number of requests to your App Configuration store, you can adjust it to a higher value.
6868

69-
1. Open the *deployment.yaml* file in the *Deployment* directory and add the following content to the `spec.containers` section. Your application will load configuration from a volume-mounted file the App Configuration Kubernetes provider generates. By setting this environment variable, your application can [ use polling to monitor changes in mounted files](/dotnet/api/microsoft.extensions.fileproviders.physicalfileprovider.usepollingfilewatcher).
69+
1. Open the *deployment.yaml* file in the *Deployment* directory and add the following content to the `spec.containers` section. Your application loads configuration from a volume-mounted file the App Configuration Kubernetes provider generates. By setting this environment variable, your application can [ use polling to monitor changes in mounted files](/dotnet/api/microsoft.extensions.fileproviders.physicalfileprovider.usepollingfilewatcher).
7070

7171
```yaml
7272
env:
7373
- name: DOTNET_USE_POLLING_FILE_WATCHER
7474
value: "true"
7575
```
7676

77-
1. Run the following command to deploy the change. Replace the namespace if you are using your existing AKS application.
77+
1. Run the following command to deploy the change. Replace the namespace if you're using your existing AKS application.
7878

7979
```console
8080
kubectl apply -f ./Deployment -n appconfig-demo
@@ -92,7 +92,7 @@ Add the following key-value to your App Configuration store. For more informatio
9292
| Settings:Message | Hello from Azure App Configuration - now with live updates! |
9393
| Settings:Sentinel | 2 |
9494

95-
1. After refreshing the browser a few times, you will see the updated content once the ConfigMap is updated in 30 seconds.
95+
1. After refreshing the browser a few times, you'll see the updated content once the ConfigMap is updated in 30 seconds.
9696

9797
![Screenshot of the web app with updated values.](./media/quickstarts/kubernetes-provider-app-launch-dynamic-after.png)
9898

articles/azure-app-configuration/howto-targetingfilter-aspnet-core.md

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Enable staged rollout of features for targeted audiences
33
titleSuffix: Azure App Configuration
4-
description: Learn how to enable staged rollout of features for targeted audiences
4+
description: Learn how to enable staged rollout of features for targeted audiences.
55
ms.service: azure-app-configuration
66
ms.devlang: csharp
77
author: maud-lv
@@ -12,9 +12,9 @@ ms.date: 02/16/2024
1212

1313
# Enable staged rollout of features for targeted audiences
1414

15-
Feature flags allow you to dynamically activate or deactivate functionality in your application. Feature filters determine the state of a feature flag each time it's evaluated. The `Microsoft.FeatureManagement` library includes `TargetingFilter`, which enables a feature flag for a specified list of users and groups, or for a specified percentage of users. `TargetingFilter` is "sticky." This means that once an individual user receives a feature, they'll continue to see that feature on all future requests. You can use `TargetingFilter` to enable a feature for a specific account during a demo, to progressively roll out new features to users in different groups or "rings," and much more.
15+
Feature flags allow you to dynamically activate or deactivate functionality in your application. Feature filters determine the state of a feature flag each time it's evaluated. The `Microsoft.FeatureManagement` library includes `TargetingFilter`, which enables a feature flag for a specified list of users and groups, or for a specified percentage of users. `TargetingFilter` is "sticky." This means that once an individual user receives a feature, they'll continue to see that feature on all future requests. You can use `TargetingFilter` to enable a feature for a specific account during a demo, to progressively rollout new features to users in different groups or "rings," and much more.
1616

17-
In this article, you'll learn how to roll out a new feature in an ASP.NET Core web application to specified users and groups, using `TargetingFilter` with Azure App Configuration.
17+
In this article, you learn how to roll out a new feature in an ASP.NET Core web application to specified users and groups, using `TargetingFilter` with Azure App Configuration.
1818

1919
## Prerequisites
2020

@@ -23,31 +23,31 @@ In this article, you'll learn how to roll out a new feature in an ASP.NET Core w
2323

2424
## Create a web application with feature flags and authentication
2525

26-
To roll out features based on users and groups, you'll need a web application that allows users to sign in.
26+
To roll out features based on users and groups, you need a web application that allows users to sign in.
2727

28-
1. Create a web application that authenticates against a local database using the following command:
28+
1. Create a web application that authenticates against a local database using the following command.
2929

3030
```dotnetcli
3131
dotnet new mvc --auth Individual -o TestFeatureFlags
3232
```
3333

34-
1. Build and run, then select the **Register** link in the upper right corner to create a new user account. Use an email address of `[email protected]`. On the **Register Confirmation** screen, select **Click here to confirm your account**.
34+
1. Build and run. Then select the **Register** link in the upper right corner to create a new user account. Use an email address of `[email protected]`. On the **Register Confirmation** screen, select **Click here to confirm your account**.
3535

36-
1. Follow the instructions in [Quickstart: Add feature flags to an ASP.NET Core app](./quickstart-feature-flag-aspnet-core.md) to add a feature flag to your new web application.
36+
1. Follow the instructions in the [Quickstart](./quickstart-feature-flag-aspnet-core.md) to add a feature flag to your new web application.
3737

3838
1. Toggle the feature flag in App Configuration. Validate that this action controls the visibility of the **Beta** item on the navigation bar.
3939

4040
## Update the web application code to use TargetingFilter
4141

42-
At this point, you can use the feature flag to enable or disable the `Beta` feature for all users. To enable the feature flag for some users while disabling it for others, update your code to use `TargetingFilter`. In this example, you'll use the signed-in user's email address as the user ID, and the domain name portion of the email address as the group. You'll add the user and group to the `TargetingContext`. The `TargetingFilter` uses this context to determine the state of the feature flag for each request.
42+
At this point, you can use the feature flag to enable or disable the `Beta` feature for all users. To enable the feature flag for some users while disabling it for others, update your code to use `TargetingFilter`. In this example, you use the signed-in user's email address as the user ID, and the domain name portion of the email address as the group. You add the user and group to the `TargetingContext`. The `TargetingFilter` uses this context to determine the state of the feature flag for each request.
4343

4444
1. Update to the latest version of the `Microsoft.FeatureManagement.AspNetCore` package.
4545

4646
```dotnetcli
4747
dotnet add package Microsoft.FeatureManagement.AspNetCore
4848
```
4949

50-
1. Add a *TestTargetingContextAccessor.cs* file:
50+
1. Add a *TestTargetingContextAccessor.cs* file.
5151

5252
```csharp
5353
using Microsoft.AspNetCore.Http;
@@ -92,13 +92,13 @@ At this point, you can use the feature flag to enable or disable the `Beta` feat
9292
}
9393
```
9494

95-
1. In *Startup.cs*, add a reference to the *Microsoft.FeatureManagement.FeatureFilters* namespace:
95+
1. In *Startup.cs*, add a reference to the *Microsoft.FeatureManagement.FeatureFilters* namespace.
9696

9797
```csharp
9898
using Microsoft.FeatureManagement.FeatureFilters;
9999
```
100100

101-
1. Update the *ConfigureServices* method to register `TargetingFilter`, following the call to `AddFeatureManagement()`:
101+
1. Update the *ConfigureServices* method to register `TargetingFilter`, following the call to `AddFeatureManagement()`.
102102

103103
```csharp
104104
services.AddFeatureManagement()
@@ -114,7 +114,7 @@ At this point, you can use the feature flag to enable or disable the `Beta` feat
114114
services.AddSingleton<ITargetingContextAccessor, TestTargetingContextAccessor>();
115115
```
116116

117-
The entire *ConfigureServices* method will look like this:
117+
The entire *ConfigureServices* method looks like this.
118118

119119
```csharp
120120
public void ConfigureServices(IServiceCollection services)
@@ -151,20 +151,20 @@ At this point, you can use the feature flag to enable or disable the `Beta` feat
151151

152152
1. Select the **Override by Groups** and **Override by Users** checkbox.
153153

154-
1. Select the following options:
154+
1. Select the following options.
155155

156156
- **Default percentage**: 0
157157
- **Include Groups**: Enter a **Name** of _contoso.com_ and a **Percentage** of _50_
158158
- **Exclude Groups**: `contoso-xyz.com`
159159
- **Include Users**: `test@contoso.com`
160160
- **Exclude Users**: `testuser@contoso.com`
161161

162-
The feature filter screen will look like this:
162+
The feature filter screen will look like this.
163163

164164
> [!div class="mx-imgBorder"]
165165
> ![Conditional feature flag](./media/feature-flag-filter-enabled.png)
166166

167-
These settings result in the following behavior:
167+
These settings result in the following behavior.
168168

169169
- The feature flag is always disabled for user `testuser@contoso.com`, because `testuser@contoso.com` is listed in the _Exclude Users_ section.
170170
- The feature flag is always disabled for users in the `contoso-xyz.com`, because `contoso-xyz.com` is listed in the _Exclude Groups_ section.
@@ -176,7 +176,7 @@ At this point, you can use the feature flag to enable or disable the `Beta` feat
176176

177177
1. Select **Apply** to save these settings and return to the **Feature manager** screen.
178178

179-
1. The **Feature filter** for the feature flag now appears as *Targeting*. This state indicates that the feature flag will be enabled or disabled on a per-request basis, based on the criteria enforced by the *Targeting* feature filter.
179+
1. The **Feature filter** for the feature flag now appears as *Targeting*. This state indicates that the feature flag is enabled or disabled on a per-request basis, based on the criteria enforced by the *Targeting* feature filter.
180180

181181
## TargetingFilter in action
182182

@@ -191,9 +191,9 @@ The following video shows this behavior in action.
191191
> [!div class="mx-imgBorder"]
192192
> ![TargetingFilter in action](./media/feature-flags-targetingfilter.gif)
193193

194-
You can create additional users with `@contoso.com` and `@contoso-xyz.com` email addresses to see the behavior of the group settings.
194+
You can create more users with `@contoso.com` and `@contoso-xyz.com` email addresses to see the behavior of the group settings.
195195

196-
Users with `contoso-xyz.com` email addresses will not see the *Beta* item. While 50% of users with `@contoso.com` email addresses will see the *Beta* item, the other 50% won't see the *Beta* item.
196+
Users with `contoso-xyz.com` email addresses won't see the *Beta* item. While 50% of users with `@contoso.com` email addresses will see the *Beta* item, the other 50% won't see the *Beta* item.
197197

198198
## Next steps
199199

0 commit comments

Comments
 (0)