features

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 12, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultFeatureGates = []Feature{
	GPTBasedUUID,
}

DefaultFeatureGates is the list of feature gates that are added by default

Functions

This section is empty.

Types

type Feature

type Feature string

Feature is a typed string for a given feature

const (
	// GPTBasedUUID feature flag is used to enable the
	// blockdevice UUID algorithm mentioned in
	// https://github.com/openebs/openebs/pull/2666
	GPTBasedUUID Feature = "GPTBasedUUID"
)

type FeatureGate

type FeatureGate map[Feature]bool

FeatureGate type represents the map of features and the state

func ParseFeatureGate

func ParseFeatureGate(features []string, defaultFGs []Feature) (FeatureGate, error)

ParseFeatureGate parses a slice of string and create the feature-gate map

func (FeatureGate) IsEnabled

func (fg FeatureGate) IsEnabled(f Feature) bool

IsEnabled returns true if the feature is enabled

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL