limit

package
v0.0.0-...-83adff0 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2020 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	LimitConfNil          = errors.New("Config of resource limit is nil")
	LimitConfError        = errors.New("LimitConfError")
	CgroupPathNotExist    = errors.New("Cgroup Path Not Exist")
	MemCgroupPathNotExist = errors.New("Mem subgroup Not Exist")
	CpuCgroupPathNotExist = errors.New("Cpu subgroup Not Exist")
)

Functions

This section is empty.

Types

type Limit

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

func LimitRes

func LimitRes(c *LimitConf) (l *Limit, err error)

LimitRes init Limit

type LimitConf

type LimitConf struct {
	AppName         string
	CgroupPath      string
	LimitMemMB      int
	LimitMemEnabled bool
	LimitCpuCore    int
	LimitCpuEnabled bool
}

Jump to

Keyboard shortcuts

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