@InterfaceAudience.Private
@InterfaceStability.Unstable
public abstract class ResourceCalculatorPlugin
extends org.apache.hadoop.conf.Configured
Modifier and Type | Class and Description |
---|---|
static class |
ResourceCalculatorPlugin.ProcResourceValues |
Constructor and Description |
---|
ResourceCalculatorPlugin() |
Modifier and Type | Method and Description |
---|---|
abstract long |
getAvailablePhysicalMemorySize()
Obtain the total size of the available physical memory present
in the system.
|
abstract long |
getAvailableVirtualMemorySize()
Obtain the total size of the available virtual memory present
in the system.
|
abstract long |
getCpuFrequency()
Obtain the CPU frequency of on the system.
|
abstract float |
getCpuUsage()
Obtain the CPU usage % of the machine.
|
abstract long |
getCumulativeCpuTime()
Obtain the cumulative CPU time since the system is on.
|
abstract int |
getNumProcessors()
Obtain the total number of processors present on the system.
|
abstract long |
getPhysicalMemorySize()
Obtain the total size of the physical memory present in the system.
|
abstract ResourceCalculatorPlugin.ProcResourceValues |
getProcResourceValues()
Obtain resource status used by current process tree.
|
static ResourceCalculatorPlugin |
getResourceCalculatorPlugin(Class<? extends ResourceCalculatorPlugin> clazz,
org.apache.hadoop.conf.Configuration conf)
Get the ResourceCalculatorPlugin from the class name and configure it.
|
abstract long |
getVirtualMemorySize()
Obtain the total size of the virtual memory present in the system.
|
public abstract long getVirtualMemorySize()
public abstract long getPhysicalMemorySize()
public abstract long getAvailableVirtualMemorySize()
public abstract long getAvailablePhysicalMemorySize()
public abstract int getNumProcessors()
public abstract long getCpuFrequency()
public abstract long getCumulativeCpuTime()
public abstract float getCpuUsage()
@InterfaceAudience.Private @InterfaceStability.Unstable public abstract ResourceCalculatorPlugin.ProcResourceValues getProcResourceValues()
public static ResourceCalculatorPlugin getResourceCalculatorPlugin(Class<? extends ResourceCalculatorPlugin> clazz, org.apache.hadoop.conf.Configuration conf)
clazz
- class-nameconf
- configure the plugin with this.Copyright © 2013 Apache Software Foundation. All Rights Reserved.