limits

package
v0.0.0-...-6ee8545 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	MemoryTargetMetric = prometheus.NewGauge(
		prometheus.GaugeOpts{
			Namespace: util.PromNamespace,
			Name:      "max_memory_target_bytes",
			Help:      "The target for the maximum amount of memory the application can use in bytes.",
		})
)

Functions

func Validate

func Validate(cfg *Config) error

Types

type Config

type Config struct {
	TargetMemoryBytes uint64
	// contains filtered or unexported fields
}

func ParseFlags

func ParseFlags(fs *flag.FlagSet, cfg *Config) *Config

ParseFlags parses the configuration flags for logging.

type PercentageAbsoluteBytesFlag

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

PercentageAbsoluteBytesFlag is a CLI flag type representing either an absolute or relative number of bytes

func (*PercentageAbsoluteBytesFlag) Get

func (*PercentageAbsoluteBytesFlag) Set

Set implements the flag interface to set value from the CLI

func (*PercentageAbsoluteBytesFlag) SetBytes

func (t *PercentageAbsoluteBytesFlag) SetBytes(bytes uint64)

func (*PercentageAbsoluteBytesFlag) SetPercent

func (t *PercentageAbsoluteBytesFlag) SetPercent(percent int)

func (*PercentageAbsoluteBytesFlag) String

func (t *PercentageAbsoluteBytesFlag) String() string

type PercentageAbsoluteKind

type PercentageAbsoluteKind int8
const (
	Percentage PercentageAbsoluteKind = iota
	Absolute
)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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