|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.hadoop.conf.Configured
org.apache.hadoop.yarn.util.ResourceCalculatorPlugin
@InterfaceAudience.LimitedPrivate(value={"YARN","MAPREDUCE"})
@InterfaceStability.Unstable
public abstract class ResourceCalculatorPluginPlugin to calculate resource information on the system.
| Field Summary | |
|---|---|
protected String |
processPid
|
| Constructor Summary | |
|---|---|
ResourceCalculatorPlugin()
|
|
| Method Summary | |
|---|---|
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. |
static ResourceCalculatorPlugin |
getResourceCalculatorPlugin(Class<? extends ResourceCalculatorPlugin> clazz,
org.apache.hadoop.conf.Configuration conf)
Create the ResourceCalculatorPlugin from the class name and configure it. |
abstract long |
getVirtualMemorySize()
Obtain the total size of the virtual memory present in the system. |
void |
setProcessPid(String pid)
set the pid of the process for which getProcResourceValues
will be invoked |
| Methods inherited from class org.apache.hadoop.conf.Configured |
|---|
getConf, setConf |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected String processPid
| Constructor Detail |
|---|
public ResourceCalculatorPlugin()
| Method Detail |
|---|
public void setProcessPid(String pid)
getProcResourceValues
will be invoked
pid - 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()
public static ResourceCalculatorPlugin getResourceCalculatorPlugin(Class<? extends ResourceCalculatorPlugin> clazz,
org.apache.hadoop.conf.Configuration conf)
clazz - ResourceCalculator plugin class-nameconf - configure the plugin with this.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||