Feature flags are the foundation of the CloudBees Feature Management platform and can encompass many types of logic and code.
Before creating a feature flag, refer to About feature flags to learn about how feature flags work.
|
You can create three types of flags in the static API. For more information on each type, refer to:
You can also create flags via the CloudBees Feature Management dynamic API. |
When creating string and number flags, you can set predefined variation values. This is useful for values which cannot be predetermined, such as a timeout value or URL. To learn more, refer to Defining feature flag variations.
A flag can have an optional description, and any number of labels, if desired. If you add or create a label for a flag as it is being created, the labels are added to the flag in all environments. Refer to Working with labels for more information.
To ignore impression data, you can set a flag’s status to permanent. To learn more, refer to Flag status.
After creation, you can modify a flag’s description, labels, variations, or permanent status for a particular environment by going to the Settings screen for the flag in that environment. Learn more at Feature flag settings.
Creating a flag in the UI
A flag created in the CloudBees Feature Management UI is available in all environments.
To create a flag in the UI:
-
From the CloudBees Feature Management Home page, select either the Overview screen or any environment under Flags in Environments.
-
Select Create flag on the upper-right of the screen.
-
Enter your flag name. If you use the format <namespace>.<flagname>, you can filter flags by <namespace>.
-
Optionally, enter a description.
-
Optionally, enter any labels from the options, or create a new one.
-
Select a flag type from the options.
-
For string or number types only, you can optionally add any number of variations:
-
Select Variation editing off. Upon selection, Variation editing on is displayed, and Add variation is enabled.
-
Select Add variation.
-
Enter a variation value.
-
-
Optionally, select Permanent flag to set the flag to Permanent status and ignore impression data.
-
Select Create.
Your new flag is created in all environments. You can update the flag description, labels, variations, or permanent status on the Settings screen for a specific environment.