featuregates

package
v0.4.15 Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2023 License: Apache-2.0 Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateCustomFeatures

func GenerateCustomFeatures(features []string) *configv1.CustomFeatureGates

GenerateCustomFeatures generates the custom feature gates from the install config.

Types

type FeatureGate

type FeatureGate interface {
	// Enabled returns true if the key is enabled.
	Enabled(key configv1.FeatureGateName) bool
}

FeatureGate indicates whether a given feature is enabled or not This interface is heavily influenced by k8s.io/component-base, but not exactly compatible.

func FeatureGateFromFeatureSets

func FeatureGateFromFeatureSets(knownFeatureSets map[configv1.FeatureSet]*configv1.FeatureGateEnabledDisabled, fs configv1.FeatureSet, customFS *configv1.CustomFeatureGates) FeatureGate

FeatureGateFromFeatureSets creates a FeatureGate from the active feature sets.

type GatedInstallConfigFeature

type GatedInstallConfigFeature struct {
	FeatureGateName configv1.FeatureGateName
	Condition       bool
	Field           *field.Path
}

GatedInstallConfigFeature contains fields that will be used to validate that required feature gates are enabled when gated install config fields are used. FeatureGateName: openshift/api feature gate required to enable the use of Field Condition: the check which determines whether the install config field is used, if Condition evaluates to True, FeatureGateName must be enabled to pass validation. Field: the gated install config field, Field is used in the error message.

Jump to

Keyboard shortcuts

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