You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/azure-app-configuration/use-variant-feature-flags-aspnet-core.md
+4-9Lines changed: 4 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,21 +8,16 @@ ms.author: rossgrambo
8
8
ms.service: azure-app-configuration
9
9
ms.devlang: csharp
10
10
ms.topic: tutorial
11
-
ms.date: 10/10/2024
11
+
ms.date: 10/18/2024
12
12
---
13
13
14
14
# Tutorial: Use variant feature flags from Azure App Configuration in an ASP.NET application
15
15
16
16
In this tutorial, you use a variant feature flag to manage experiences for different user segments in an example application, *Quote of the Day*. You utilize the variant feature flag created in [Use variant feature flags](./use-variant-feature-flags.md). Before proceeding, ensure you create the variant feature flag named *Greeting* in your App Configuration store.
17
17
18
-
> [!div class="checklist"]
19
-
> * Set up an ASP.NET app to consume variant feature flags
20
-
21
18
## Prerequisites
22
19
23
-
* An Azure subscription. If you don’t have one, [create one for free](https://azure.microsoft.com/free/).
24
-
* An [App Configuration store](./quickstart-azure-app-configuration-create.md).
* Follow the [Use variant feature flags](./use-variant-feature-flags.md) tutorial and create the variant feature flag named *Greeting*.
26
21
27
22
## Create an ASP.NET Core web app
28
23
@@ -279,13 +274,13 @@ In this tutorial, you use a variant feature flag to manage experiences for diffe
279
274
280
275
:::image type="content" source="media/use-variant-feature-flags-aspnet-core/register.png" alt-text="Screenshot of the Quote of the day app, showing Register.":::
281
276
282
-
1. Register a new user named *[email protected]*. The password must have at least six characters and contain a number and a special character.
1. Select the link **Click here to validate email** after entering user information.
285
280
286
281
:::image type="content" source="media/use-variant-feature-flags-aspnet-core/click-to-confirm.png" alt-text="Screenshot of the Quote of the day app, showing click to confirm.":::
287
282
288
-
1. Repeat the same steps to register a second user named [email protected].
283
+
1. Repeat the same steps to register a second user named *[email protected]*.
289
284
290
285
> [!NOTE]
291
286
> It's important for the purpose of this tutorial to use these names exactly. As long as the feature has been configured as expected, the two users should see different variants.
Copy file name to clipboardExpand all lines: articles/azure-app-configuration/use-variant-feature-flags.md
+17-17Lines changed: 17 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ ms.author: rossgrambo
8
8
ms.service: azure-app-configuration
9
9
ms.devlang: csharp
10
10
ms.topic: tutorial
11
-
ms.date: 10/10/2024
11
+
ms.date: 10/18/2024
12
12
---
13
13
14
14
# Use variant feature flags
@@ -17,7 +17,7 @@ Variant feature flags enable your application to support multiple variants of a
17
17
18
18
## What is a variant feature flag?
19
19
20
-
A variant feature flag uses variants and allocation to assign values to users. Variants are defined with a **Name** and a **Configuration Value**. Name is simply an identifier to help tell variants apart. The configuration value on a variant can be any valid JSON or JSON value. Using JSON allows variants to contain as much or as little data as needed to control a feature.
20
+
A variant feature flag is an enhanced feature flag that supports multiple states or variations. While it can still be toggled on or off, it also allows for different variants with configurations. A variant is defined with a *Name* and an optional *Configuration Value*. The name is an identifier to tell variants apart. The configuration value can range from simple JSON primitives to complex JSON objects. You can use variants to differentiate functionalities or user experiences and optionally configure these functionalities or user experiences with variant configuration values. Additionally, a variant feature flag includes allocation rules, which define the target audience for each variant.
21
21
22
22
### Variants
23
23
@@ -48,29 +48,29 @@ You can assign variants to specific groups or users irrespective of the percenta
48
48
### Default variants and kill switch
49
49
50
50
Variant feature flags have two variant defaults, **DefaultWhenEnabled** and **DefaultWhenDisabled**.
51
-
1. The **DefaultWhenEnabled** variant takes effect if the flag is enabled but the allocation does assign all percentiles. Any user placed in an unassigned percentile receives the **DefaultWhenEnabled** variant.
51
+
1. The **DefaultWhenEnabled** variant takes effect if the flag is enabled but the allocation doesn't assign all percentiles. Any user placed in an unassigned percentile receives the **DefaultWhenEnabled** variant.
52
52
1. The **DefaultWhenDisabled** variant takes effect if the flag is disabled, done by setting the **Enabled** field to false, also known as using the "kill switch".
53
53
54
-
The **kill switch** is used to stop users from allocating. Used when one or more of the variants have a problem- whether it's a bug, regression, or bad performance. To use the kill switch, set the **Enabled** field of the variant flag to false. All users now are given the **DefaultWhenDisabled** variant, regardless of which percentiles they were a part of.
54
+
The **kill switch** is used to stop users from allocating. Used when one or more of the variants have a problem- whether it's a bug, regression, or bad performance. To use the kill switch, set the **Enabled** field of the variant flag to false. All users now are given the **DefaultWhenDisabled** variant, regardless of which percentiles or overridden users/groups they were a part of.
55
55
56
56
## Build an app with a variant feature flag
57
57
58
-
In this tutorial, you create a web app named _Quote of the Day_. When the app is loaded, it displays a quote. Users can interact with the heart button to like it. To improve user engagement, you want to explore whether a personalized greeting message increases the number of users who like the quote. Users who receive the _None_ variant see no greeting. Users who receive the _Simple_ variant get a simple greeting message. Users who receive the _Long_ variant get a slightly longer greeting.
58
+
In this tutorial, you create a web app named _Quote of the Day_. When the app is loaded, it displays a quote. Users can interact with the heart button to like it. To improve user engagement, you want to explore whether a personalized greeting message increases the number of users who like the quote. Users who receive the _None_ variant see no greeting. Users who receive the _Simple_ variant get a simple greeting message. Users who receive the _Long_ variant get a slightly longer greeting.
59
59
60
-
1. Create a variant feature flag called *Greeting* with no label in your App Configuration store. It includes three variants: *None*, *Simple*, and *Long*, each corresponding to different greeting messages. Refer to the following table for their configuration values and allocation settings. For more information on how to add a variant feature flag, see [Create a variant feature flag](./manage-feature-flags.md#create-a-variant-feature-flag).
60
+
## Prerequisites
61
61
62
-
| Variant Name | Variant Configuration Value | Allocation|
63
-
|---|---|---|
64
-
| None *(Default)*| null | 50% |
65
-
| Simple | "Hello!" | 25% |
66
-
| Long | "I hope this makes your day!" | 25% |
62
+
* An Azure subscription. If you don’t have one, [create one for free](https://azure.microsoft.com/free/).
63
+
* An [App Configuration store](./quickstart-azure-app-configuration-create.md).
67
64
68
-
2. Continue to the following instructions to use the variant feature flag in your application for the language or platform you're using.
1. Create a variant feature flag called *Greeting* with no label in your App Configuration store. It includes three variants: *None*, *Simple*, and *Long*, each corresponding to different greeting messages. Refer to the following table for their configuration values and allocation settings. For more information on how to add a variant feature flag, see [Create a variant feature flag](./manage-feature-flags.md#create-a-variant-feature-flag).
72
68
73
-
For the full feature rundown of the .NET feature management library, refer to the following document.
69
+
| Variant Name | Variant Configuration Value | Allocation|
0 commit comments