Skip to content
This repository was archived by the owner on Nov 1, 2023. It is now read-only.

Commit 9f8a8a0

Browse files
tevoineaAdamL-Microsoft
authored andcommitted
Feature flag work item creation (#3353)
1 parent 9d50867 commit 9f8a8a0

File tree

3 files changed

+15
-1
lines changed

3 files changed

+15
-1
lines changed

src/ApiService/ApiService/FeatureFlags.cs

+1
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,5 @@ public static class FeatureFlagConstants {
77
public const string EnableCustomMetricTelemetry = "EnableCustomMetricTelemetry";
88
public const string EnableBlobRetentionPolicy = "EnableBlobRetentionPolicy";
99
public const string EnableDryRunBlobRetention = "EnableDryRunBlobRetention";
10+
public const string EnableWorkItemCreation = "EnableWorkItemCreation";
1011
}

src/ApiService/ApiService/onefuzzlib/NotificationOperations.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public async Async.Task NewFiles(Container container, string filename, bool isLa
3030
var notifications = GetNotifications(container);
3131
var hasNotifications = await notifications.AnyAsync();
3232
var reportOrRegression = await _context.Reports.GetReportOrRegression(container, filename, expectReports: hasNotifications);
33-
if (hasNotifications) {
33+
if (hasNotifications && await _context.FeatureManagerSnapshot.IsEnabledAsync(FeatureFlagConstants.EnableWorkItemCreation)) {
3434
var done = new List<NotificationTemplate>();
3535
await foreach (var notification in notifications) {
3636
if (done.Contains(notification.Config)) {

src/deployment/bicep-templates/feature-flags.bicep

+13
Original file line numberDiff line numberDiff line change
@@ -76,4 +76,17 @@ resource enableDryRunBlobRetentionFeatureFlag 'Microsoft.AppConfiguration/config
7676
}
7777
}
7878

79+
resource enableWorkItemCreation 'Microsoft.AppConfiguration/configurationStores/keyValues@2021-10-01-preview' = {
80+
parent: featureFlags
81+
name: '.appconfig.featureflag~2FEnableWorkItemCreation'
82+
properties: {
83+
value: string({
84+
id: 'EnableWorkItemCreation'
85+
description: 'Create work items'
86+
enabled: false
87+
})
88+
contentType: 'application/vnd.microsoft.appconfig.ff+json;charset=utf-8'
89+
}
90+
}
91+
7992
output AppConfigEndpoint string = 'https://${appConfigName}.azconfig.io'

0 commit comments

Comments
 (0)