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
Document procedure for adding, consuming and changing feature flags.
The PR below adds feature flag capabilities to InfluxDB to allow users to exercise experimental features before they are enabled by default.
A feature flag is created by updating flags.yml and running make flags. It includes a default value.
A feature flag is then consumed in code:
On the backend, a flag can be used like this
iffeature.MyFeatureFlag().Enabled(ctx) {
// new code path...
} else {
// old code path...
}
On the frontend, a similar pattern can be used based on the response from /api/v2/flags
Finally, the value of a flag can be changed from the default using the INFLUXD_FEATURE_FLAGS environment variable or --feature-flags CLI flag. In the first case, the environment variable should be formatted as a JSON map of string keys to string values, e.g.
In the the second case, the flag value should be formatted as a comma-delimted list of key-value pairs, with an equals sign as an assignment operator, e.g.
@noramullen1@gavincabbage There has been discussion around leaving this feature undocumented. I don't know that we've come to a consensus yet, but I think we better put this on hold.
Document procedure for adding, consuming and changing feature flags.
The PR below adds feature flag capabilities to InfluxDB to allow users to exercise experimental features before they are enabled by default.
A feature flag is created by updating
flags.yml
and runningmake flags
. It includes a default value.A feature flag is then consumed in code:
/api/v2/flags
Finally, the value of a flag can be changed from the default using the
INFLUXD_FEATURE_FLAGS
environment variable or--feature-flags
CLI flag. In the first case, the environment variable should be formatted as a JSON map of string keys to string values, e.g.In the the second case, the flag value should be formatted as a comma-delimted list of key-value pairs, with an equals sign as an assignment operator, e.g.
Relevant URLs
What products and version are you using?
InfluxDB 2.0
The text was updated successfully, but these errors were encountered: