Modifier and Type | Field and Description |
---|---|
private static final Object | |
private static volatile CgroupV2Subsystem | |
private static final int[] | |
private static final long[] | |
private static final long | |
private static final int | |
private static final String | |
private final CgroupSubsystemController |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public long | getBlkIOServiceCount()
Implements jdk. |
public long | getBlkIOServiced()
Implements jdk. |
public long | getCpuNumPeriods()
Implements jdk. |
public long | getCpuNumThrottled()
Implements jdk. |
public long | getCpuPeriod()
Implements jdk. |
public long | getCpuQuota()
Implements jdk. |
private int[] | |
public int[] | getCpuSetCpus()
Implements jdk. |
public int[] | getCpuSetMems()
Implements jdk. |
public long | getCpuShares()
Implements jdk. |
public long | getCpuSystemUsage()
Implements jdk. |
public long | getCpuThrottledTime()
Implements jdk. |
public long | getCpuUsage()
Implements jdk. |
public long | getCpuUserUsage()
Implements jdk. |
public long | getEffectiveCpuCount()
Implements jdk. |
public int[] | getEffectiveCpuSetCpus()
Implements jdk. |
public int[] | getEffectiveCpuSetMems()
Implements jdk. |
private long | |
public static CgroupSubsystem | Returns: A singleton CgroupSubsystem instance, never null.Get the singleton instance of a cgroups v2 subsystem. |
private long | |
private long | |
public long | getMemoryAndSwapLimit()
Implements jdk. |
public long | getMemoryAndSwapUsage()
Implements jdk. |
public long | getMemoryFailCount()
Implements jdk. |
public long | getMemoryLimit()
Implements jdk. |
public long | getMemorySoftLimit()
Implements jdk. |
public long | getMemoryUsage()
Implements jdk. |
public long[] | getPerCpuUsage()
Implements jdk. |
public long | getPidsCurrent()
Implements jdk. |
public long | getPidsMax()
Implements jdk. |
public String | getProvider()
Implements jdk. |
private static String[] | |
private static String[] | |
public long | getTcpMemoryUsage()
Implements jdk. |
private static Long | |
public static Long | |
public static Long | |
private static long | |
private long |
EMPTY_STR | back to summary |
---|---|
private static final Object EMPTY_STR |
INSTANCE | back to summary |
---|---|
private static volatile CgroupV2Subsystem INSTANCE |
INT_ARRAY_UNAVAILABLE | back to summary |
---|---|
private static final int[] INT_ARRAY_UNAVAILABLE |
LONG_ARRAY_NOT_SUPPORTED | back to summary |
---|---|
private static final long[] LONG_ARRAY_NOT_SUPPORTED |
NO_SWAP | back to summary |
---|---|
private static final long NO_SWAP |
PER_CPU_SHARES | back to summary |
---|---|
private static final int PER_CPU_SHARES |
PROVIDER_NAME | back to summary |
---|---|
private static final String PROVIDER_NAME |
unified | back to summary |
---|---|
private final CgroupSubsystemController unified |
CgroupV2Subsystem | back to summary |
---|---|
private CgroupV2Subsystem(CgroupSubsystemController unified) |
getBlkIOServiceCount | back to summary |
---|---|
public long getBlkIOServiceCount() Implements jdk. Doc from jdk. Returns the number of block I/O requests to the disk that have been issued by the Isolation Group.
|
getBlkIOServiced | back to summary |
---|---|
public long getBlkIOServiced() Implements jdk. Doc from jdk. Returns the number of block I/O bytes that have been transferred to/from the disk by the Isolation Group.
|
getCpuNumPeriods | back to summary |
---|---|
public long getCpuNumPeriods() Implements jdk. Doc from jdk. Returns the number of time-slice periods that have elapsed if a CPU quota has been setup for the Isolation Group
|
getCpuNumThrottled | back to summary |
---|---|
public long getCpuNumThrottled() Implements jdk. Doc from jdk. Returns the number of time-slice periods that the group has been throttled or limited due to the group exceeding its quota if a CPU quota has been setup for the Isolation Group.
|
getCpuPeriod | back to summary |
---|---|
public long getCpuPeriod() Implements jdk. Doc from jdk. Returns the length of the scheduling period, in microseconds, for processes within the Isolation Group.
|
getCpuQuota | back to summary |
---|---|
public long getCpuQuota() Implements jdk. Doc from jdk. Returns the total available run-time allowed, in microseconds, during each scheduling period for all tasks in the Isolation Group.
|
getCpuSet | back to summary |
---|---|
private int[] getCpuSet(String cpuSetVal) |
getCpuSetCpus | back to summary |
---|---|
public int[] getCpuSetCpus() Implements jdk. Doc from jdk. Returns the CPUS that are available for execution of processes
in the current Isolation Group. The size of the array is equal
to the total number of CPUs and the elements in the array are the
physical CPU numbers that are available. Some of the CPUs returned
may be offline. To get the current online CPUs, use
|
getCpuSetMems | back to summary |
---|---|
public int[] getCpuSetMems() Implements jdk. Doc from jdk. Returns the memory nodes that are available for use by processes
in the current Isolation Group. The size of the array is equal
to the total number of nodes and the elements in the array are the
physical node numbers that are available. Some of the nodes returned
may be offline. To get the current online memory nodes, use
|
getCpuShares | back to summary |
---|---|
public long getCpuShares() Implements jdk. Doc from jdk. Returns the relative weighting of processes with the Isolation Group used for prioritizing the scheduling of processes across all Isolation Groups running on a host.
|
getCpuSystemUsage | back to summary |
---|---|
public long getCpuSystemUsage() Implements jdk. Doc from jdk. Returns the aggregate system time, in nanoseconds, consumed by all tasks in the Isolation Group.
|
getCpuThrottledTime | back to summary |
---|---|
public long getCpuThrottledTime() Implements jdk. Doc from jdk. Returns the total time duration, in nanoseconds, that the group has been throttled or limited due to the group exceeding its quota if a CPU quota has been setup for the Isolation Group.
|
getCpuUsage | back to summary |
---|---|
public long getCpuUsage() Implements jdk. Doc from jdk. Returns the aggregate time, in nanoseconds, consumed by all tasks in the Isolation Group.
|
getCpuUserUsage | back to summary |
---|---|
public long getCpuUserUsage() Implements jdk. Doc from jdk. Returns the aggregate user time, in nanoseconds, consumed by all tasks in the Isolation Group.
|
getEffectiveCpuCount | back to summary |
---|---|
public long getEffectiveCpuCount() Implements jdk. Doc from jdk. Returns the number of effective processors that this Isolation
group has available to it. This effective processor count is
computed based on the number of dedicated CPUs, CPU shares and
CPU quotas in effect for this isolation group.
This method returns the same value as
|
getEffectiveCpuSetCpus | back to summary |
---|---|
public int[] getEffectiveCpuSetCpus() Implements jdk. Doc from jdk. Returns the CPUS that are available and online for execution of processes within the current Isolation Group. The size of the array is equal to the total number of CPUs and the elements in the array are the physical CPU numbers.
|
getEffectiveCpuSetMems | back to summary |
---|---|
public int[] getEffectiveCpuSetMems() Implements jdk. Doc from jdk. Returns the memory nodes that are available and online for use by processes within the current Isolation Group. The size of the array is equal to the total number of nodes and the elements in the array are the physical node numbers.
|
getFromCpuMax | back to summary |
---|---|
private long getFromCpuMax(int tokenIdx) |
getInstance | back to summary |
---|---|
public static CgroupSubsystem getInstance(CgroupInfo anyController) Get the singleton instance of a cgroups v2 subsystem. On initialization, a new object from the given cgroup information 'anyController' is being created. Note that the cgroup information has been parsed from cgroup interface files ahead of time. See CgroupSubsystemFactory.determineType() for the cgroup interface files parsing logic.
|
getLongVal | back to summary |
---|---|
private long getLongVal(String file, long defaultValue) |
getLongVal | back to summary |
---|---|
private long getLongVal(String file) |
getMemoryAndSwapLimit | back to summary |
---|---|
public long getMemoryAndSwapLimit() Implements jdk. Note that for cgroups v2 the actual limits set for swap and memory live in two different files, memory.swap.max and memory.max respectively. In order to properly report a cgroup v1 like compound value we need to sum the two values. Setting a swap limit without also setting a memory limit is not allowed.
|
getMemoryAndSwapUsage | back to summary |
---|---|
public long getMemoryAndSwapUsage() Implements jdk. Note that for cgroups v2 the actual values set for swap usage and memory usage live in two different files, memory.current and memory.swap.current respectively. In order to properly report a cgroup v1 like compound value we need to sum the two values. Setting a swap limit without also setting a memory limit is not allowed.
|
getMemoryFailCount | back to summary |
---|---|
public long getMemoryFailCount() Implements jdk. Doc from jdk. Returns the number of times that user memory requests in the Isolation Group have exceeded the memory limit.
|
getMemoryLimit | back to summary |
---|---|
public long getMemoryLimit() Implements jdk. Doc from jdk. Returns the maximum amount of physical memory, in bytes, that can be allocated in the Isolation Group.
|
getMemorySoftLimit | back to summary |
---|---|
public long getMemorySoftLimit() Implements jdk. Doc from jdk. Returns the hint to the operating system that allows groups to specify the minimum amount of physical memory that they need to achieve reasonable performance in low memory systems. This allows host systems to provide greater sharing of memory.
|
getMemoryUsage | back to summary |
---|---|
public long getMemoryUsage() Implements jdk. Doc from jdk. Returns the amount of physical memory, in bytes, that is currently allocated in the current Isolation Group.
|
getPerCpuUsage | back to summary |
---|---|
public long[] getPerCpuUsage() Implements jdk. Doc from jdk. Returns the aggregate time, in nanoseconds, consumed by all tasks in the Isolation Group, separated by CPU. If the current process is running within a container, the reported time will only be valid for processes running within the same container. The values are returned in an array, one entry for each physical processor on the system. Time values for processors unavailable to this Group are undefined.
|
getPidsCurrent | back to summary |
---|---|
public long getPidsCurrent() Implements jdk. Doc from jdk. Returns the current number of tasks in the Isolation Group.
|
getPidsMax | back to summary |
---|---|
public long getPidsMax() Implements jdk. Doc from jdk. Returns the maximum number of tasks that may be created in the Isolation Group.
|
getProvider | back to summary |
---|---|
public String getProvider() Implements jdk. Doc from jdk. Returns the interface responsible for providing the platform metrics. |
getRWBytesIOMatchTokenNames | back to summary |
---|---|
private static String[] getRWBytesIOMatchTokenNames() |
getRWIOMatchTokenNames | back to summary |
---|---|
private static String[] getRWIOMatchTokenNames() |
getTcpMemoryUsage | back to summary |
---|---|
public long getTcpMemoryUsage() Implements jdk. Doc from jdk. Returns the amount of networking physical memory, in bytes, that is currently allocated in the current Isolation Group.
|
ioStatLineToLong | back to summary |
---|---|
private static Long ioStatLineToLong(String line, String[] matchNames) |
lineToRandWIOs | back to summary |
---|---|
public static Long lineToRandWIOs(String line) |
lineToRBytesAndWBytesIO | back to summary |
---|---|
public static Long lineToRBytesAndWBytesIO(String line) |
longOrZero | back to summary |
---|---|
private static long longOrZero(String val) |
sumTokensIOStat | back to summary |
---|---|
private long sumTokensIOStat(Function<String, Long> mapFunc) |