featureflag

package
v18.8.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Dummy is a feature flag for demonstration and testing purposes.
	Dummy = NewFeatureFlag(
		"dummy",
		false,
	)
)

Functions

func NewCheckCounter

func NewCheckCounter(meter otelmetric.Meter) (otelmetric.Int64Counter, error)

Types

type FeatureFlag

type FeatureFlag struct {
	Name    string
	Default bool
	// contains filtered or unexported fields
}

func NewFeatureFlag

func NewFeatureFlag(name string, defaultValue bool) *FeatureFlag

type Set

type Set struct {
	// contains filtered or unexported fields
}

func NewSet

func NewSet(ffs map[string]bool, checkCounter otelmetric.Int64Counter) Set

func (Set) IsDisabled

func (s Set) IsDisabled(ff *FeatureFlag) bool

func (Set) IsEnabled

func (s Set) IsEnabled(ff *FeatureFlag) bool

func (Set) ToMap

func (s Set) ToMap() map[string]bool

Jump to

Keyboard shortcuts

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