package
1.33.0-alpha.2
Repository: https://github.com/kubernetes/kubernetes.git
Documentation: pkg.go.dev

# Packages

# Functions

GetCgroupSubsystems returns information about the mounted cgroup subsystems.
GetKubeletContainer returns the cgroup the kubelet will use.
GetPodCgroupNameSuffix returns the last element of the pod CgroupName identifier.
HugePageLimits converts the API representation to a map from huge page size (in bytes) to huge page limit (in bytes).
MilliCPUToQuota converts milliCPU to CFS quota and period values.
MilliCPUToShares converts the milliCPU to CFS shares.
NewCgroupManager is a factory method that returns a CgroupManager.
NewCgroupName composes a new cgroup name.
TODO(vmarmol): Add limits to the system containers.
NodeAllocatableRoot returns the literal cgroup path for the node allocatable cgroup.
ParseQOSReserved parses the --qos-reserved option.
ResourceConfigForPod takes the input pod and outputs the cgroup resource config.

# Constants

Cgroup2MemoryHigh is memory.high for cgroup v2.
Cgroup2MemoryMin is memory.min for cgroup v2.
Warning message for the users still using cgroup v1.
Warning message for the users using cgroup v2 on kernel doesn't support root `cpu.stat`.
From the inverse of the conversion in MilliCPUToQuota: MinQuotaPeriod * MilliCPUToCPU / QuotaPeriod.
1000 microseconds is equivalent to 1ms defined here: https://github.com/torvalds/linux/blob/cac03ac368fabff0122853de2422d4e17a32de08/kernel/sched/core.c#L10546.
These limits are defined in the kernel: https://github.com/torvalds/linux/blob/0bddd227f3dc55975e2b8dfa7fc6f959b062a2c7/kernel/sched/sched.h#L427-L428.
100000 microseconds is equivalent to 100ms.

# Variables

# Structs

CgroupConfig holds the cgroup configuration information.
CgroupSubsystems holds information about the mounted cgroup subsystems.
QOSContainersInfo stores the names of containers per qos.
ResourceConfig holds information about all the supported cgroup resource parameters.

# Interfaces

CgroupManager allows for cgroup management.
Manages the containers running on a machine.
PodContainerManager stores and manages pod level containers The Pod workers interact with the PodContainerManager to create and destroy containers for the pod.

# Type aliases

CgroupName is the abstract name of a cgroup prior to any driver specific conversion.