Skip to content

Commit e2c30be

Browse files
committed
Add default kv and ff samples
1 parent b568bc1 commit e2c30be

File tree

1 file changed

+62
-12
lines changed

1 file changed

+62
-12
lines changed

docs/AzureFrontDoor/readme.md

Lines changed: 62 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,44 @@ The key-value filters used by your application must match exactly the filters co
1515

1616
Here are some examples to help you set up the right filters.
1717

18-
- [Application uses key-values only](#application-uses-key-values-only)
19-
- [Application uses feature flags only](#application-uses-feature-flags-only)
18+
- [Application uses default key-values](#application-uses-default-key-values)
19+
- [Application uses key-values selector](#application-uses-key-values-selector)
20+
- [Application uses default feature flags](#application-uses-default-feature-flags)
21+
- [Application uses feature flags selector](#application-uses-feature-flags-selector)
2022
- [Application uses key-values and feature flags](#application-uses-key-values-and-feature-flags)
2123
- [Application uses multiple key-value selectors](#application-uses-multiple-key-value-selectors)
2224
- [Application uses key-values and snapshot selectors](#application-uses-key-values-and-snapshot-selectors)
2325
- [Application uses snapshot reference](#application-uses-snapshot-reference)
2426
- [Application loads key-values with reserved characters](#application-loads-key-values-with-reserved-characters)
2527
- [Application loads key-values with tag filters](#application-loads-key-values-with-tag-filters)
2628

29+
### Application uses default key-values
2730

28-
### Application uses key-values only
31+
If your application has the following set up:
2932

30-
If you application has the following set up:
33+
```cs
34+
builder.Configuration.AddAzureAppConfiguration(options =>
35+
{
36+
options.ConnectAzureFrontDoor(new Uri("{YOUR-AFD-ENDPOINT}"))
37+
.ConfigureRefresh(refreshOptions =>
38+
{
39+
refreshOptions.RegisterAll()
40+
.SetRefreshInterval(TimeSpan.FromMinutes(1));
41+
});
42+
});
43+
```
44+
45+
Then your Azure Front Door filters should look like this:
46+
47+
48+
| **Filter Type** | **Operator** | **Value** | **Operator** | **Value** |
49+
| ---------------- | ------------- | ----------- | ------------- | ----------- |
50+
| Key value | Key All | `*` | Label Equal | `(No label)` |
51+
52+
53+
### Application uses key-values selector
54+
55+
If your application has the following set up with for loading specific key-values:
3156

3257
```cs
3358
builder.Configuration.AddAzureAppConfiguration(options =>
@@ -47,16 +72,41 @@ Then your Azure Front Door filters should look like this:
4772

4873
| **Filter Type** | **Operator** | **Value** | **Operator** | **Value** |
4974
| ---------------- | ------------- | ----------- | ------------- | ----------- |
50-
| Key value | Key Starts with | `App1:` | Label Equal | `(No label)` |
75+
| Key value | Key Starts with | `App1:` | Label Equal | `(No label)`|
5176

5277

5378
![AFD Portal Filters](./images/sample1.png)
5479

5580
-------
5681

57-
### Application uses feature flags only
82+
### Application uses default feature flags
83+
84+
If your application has the following set up for loading default feature flags:
85+
86+
```cs
87+
builder.Configuration.AddAzureAppConfiguration(options =>
88+
{
89+
options.ConnectAzureFrontDoor(new Uri("{YOUR-AFD-ENDPOINT}"))
90+
.UseFeatureFlags(ffOptions =>
91+
{
92+
ffOptions.SetRefreshInterval(TimeSpan.FromMinutes(1));
93+
});
94+
});
95+
```
96+
97+
Then your Azure Front Door filters should look like this:
98+
99+
100+
| **Filter Type** | **Operator** | **Value** | **Operator** | **Value** |
101+
| ---------------- | ------------- | ----------- | ------------- | ----------- |
102+
| Key value | Key All | `*` | Label Equal | `(No label)` |
103+
| Key value | Key Starts with | `.appconfig.featureflag/` | Label Equal | `(No label)` |
104+
105+
-------
106+
107+
### Application uses feature flags selector
58108

59-
If you application has the following set up for loading only feature flags:
109+
If your application has the following set up for loading specific feature flags:
60110

61111
```cs
62112
builder.Configuration.AddAzureAppConfiguration(options =>
@@ -82,7 +132,7 @@ Then your Azure Front Door filters should look like this:
82132

83133
### Application uses key-values and feature flags
84134

85-
If you application has the following set up for loading key-values and feature flags:
135+
If your application has the following set up for loading key-values and feature flags:
86136

87137
```cs
88138
builder.Configuration.AddAzureAppConfiguration(options =>
@@ -114,7 +164,7 @@ Then your Azure Front Door filters should look like this:
114164

115165
### Application uses multiple key-value selectors
116166

117-
If you application has the following set up with multiple selectors:
167+
If your application has the following set up with multiple selectors:
118168

119169
```cs
120170
builder.Configuration.AddAzureAppConfiguration(options =>
@@ -141,7 +191,7 @@ Then your Azure Front Door filters should look like this:
141191

142192
### Application uses key-values and snapshot selectors
143193

144-
If you application has the following set up with key-values and snapshot:
194+
If your application has the following set up with key-values and snapshot:
145195

146196
```cs
147197
builder.Configuration.AddAzureAppConfiguration(options =>
@@ -206,7 +256,7 @@ Then you need to add "snapshot1" to your Azure Front Door filters, in addition t
206256

207257
### Application loads key-values with reserved characters
208258

209-
If you application has the following set up where your key filter contains App Config reserved characters (`, * \`):
259+
If your application has the following set up where your key filter contains [App Config reserved characters](https://aka.ms/azconfig/docs/keyvaluefiltering):
210260

211261
```cs
212262
builder.Configuration.AddAzureAppConfiguration(options =>
@@ -234,7 +284,7 @@ Then your Azure Front Door filters should look like this:
234284

235285
### Application loads key-values with tag filters
236286

237-
If you application has the following set up with tag filters:
287+
If your application has the following set up with tag filters:
238288

239289
```cs
240290
builder.Configuration.AddAzureAppConfiguration(options =>

0 commit comments

Comments
 (0)