Skip to content

Commit

Permalink
feat: add new feature flags
Browse files Browse the repository at this point in the history
Experimental features from Labs

JIRA: F1-190
  • Loading branch information
Vojtasii committed Apr 16, 2024
1 parent 7b8139d commit 302de2d
Show file tree
Hide file tree
Showing 2 changed files with 66 additions and 0 deletions.
42 changes: 42 additions & 0 deletions libs/sdk-backend-tiger/src/backend/features/feature.ts
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,48 @@ export function mapFeatures(features: FeaturesMap): Partial<ITigerFeatureFlags>
"BOOLEAN",
FeatureFlagsValues.enableOracleDataSource,
),
...loadFeature(
features,
TigerFeaturesNames.EnableAnalyticalCatalog,
"enableAnalyticalCatalog",
"BOOLEAN",
FeatureFlagsValues.enableAnalyticalCatalog,
),
...loadFeature(
features,
TigerFeaturesNames.EnableAlerting,
"enableAlerting",
"BOOLEAN",
FeatureFlagsValues.enableAlerting,
),
...loadFeature(
features,
TigerFeaturesNames.EnableLabsSmartFunctions,
"enableLabsSmartFunctions",
"BOOLEAN",
FeatureFlagsValues.enableLabsSmartFunctions,
),
...loadFeature(
features,
TigerFeaturesNames.EnableKeyDriverAnalysis,
"enableKeyDriverAnalysis",
"BOOLEAN",
FeatureFlagsValues.enableKeyDriverAnalysis,
),
...loadFeature(
features,
TigerFeaturesNames.EnableDataProfiling,
"enableDataProfiling",
"BOOLEAN",
FeatureFlagsValues.enableDataProfiling,
),
...loadFeature(
features,
TigerFeaturesNames.EnableExperimentalFeaturesUI,
"enableExperimentalFeaturesUI",
"BOOLEAN",
FeatureFlagsValues.enableExperimentalFeaturesUI,
),
};
}

Expand Down
24 changes: 24 additions & 0 deletions libs/sdk-backend-tiger/src/backend/uiFeatures.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,12 @@ export enum TigerFeaturesNames {
EnableMultipleCSVs = "enableMultipleCSVs",
//boolean
EnableOracleDataSource = "enableOracleDataSource",
EnableAnalyticalCatalog = "enableAnalyticalCatalog",
EnableAlerting = "enableAlerting",
EnableLabsSmartFunctions = "enableLabsSmartFunctions",
EnableKeyDriverAnalysis = "enableKeyDriverAnalysis",
EnableDataProfiling = "enableDataProfiling",
EnableExperimentalFeaturesUI = "enableExperimentalFeaturesUI",
}

export type ITigerFeatureFlags = {
Expand Down Expand Up @@ -118,6 +124,12 @@ export type ITigerFeatureFlags = {
enableKDAttributeFilterDatesValidation: typeof FeatureFlagsValues["enableKDAttributeFilterDatesValidation"][number];
enableMultipleCSVs: typeof FeatureFlagsValues["enableMultipleCSVs"][number];
enableOracleDataSource: typeof FeatureFlagsValues["enableOracleDataSource"][number];
enableAnalyticalCatalog: typeof FeatureFlagsValues["enableAnalyticalCatalog"][number];
enableAlerting: typeof FeatureFlagsValues["enableAlerting"][number];
enableLabsSmartFunctions: typeof FeatureFlagsValues["enableLabsSmartFunctions"][number];
enableKeyDriverAnalysis: typeof FeatureFlagsValues["enableKeyDriverAnalysis"][number];
enableDataProfiling: typeof FeatureFlagsValues["enableDataProfiling"][number];
enableExperimentalFeaturesUI: typeof FeatureFlagsValues["enableExperimentalFeaturesUI"][number];
};

export const DefaultFeatureFlags: ITigerFeatureFlags = {
Expand Down Expand Up @@ -159,6 +171,12 @@ export const DefaultFeatureFlags: ITigerFeatureFlags = {
enableKDAttributeFilterDatesValidation: true,
enableMultipleCSVs: false,
enableOracleDataSource: false,
enableAnalyticalCatalog: false,
enableAlerting: false,
enableLabsSmartFunctions: false,
enableKeyDriverAnalysis: false,
enableDataProfiling: false,
enableExperimentalFeaturesUI: false,
};

export const FeatureFlagsValues = {
Expand Down Expand Up @@ -204,4 +222,10 @@ export const FeatureFlagsValues = {
enableKDAttributeFilterDatesValidation: [true, false] as const,
enableMultipleCSVs: [true, false] as const,
enableOracleDataSource: [true, false] as const,
enableAnalyticalCatalog: [true, false] as const,
enableAlerting: [true, false] as const,
enableLabsSmartFunctions: [true, false] as const,
enableKeyDriverAnalysis: [true, false] as const,
enableDataProfiling: [true, false] as const,
enableExperimentalFeaturesUI: [true, false] as const,
};

0 comments on commit 302de2d

Please sign in to comment.