|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectentropy.monitoring.ConfigurationAdapter
public abstract class ConfigurationAdapter
Extract a configuration from a monitoring system.
| Field Summary | |
|---|---|
static int |
DEFAULT_CPU_STEP
Default step to round CPU capacity and consumption. |
| Constructor Summary | |
|---|---|
ConfigurationAdapter()
Make a new Configuration adapter. |
|
| Method Summary | |
|---|---|
abstract Configuration |
extractConfiguration()
Get the current configuration. |
static int |
getCPUCapacity(int mhz,
int nbCPU)
Get a CPU value using current metrics and default step. |
static int |
getCPUConsumption(float cpuPct,
Node host)
Get the CPU consumption of a virtual machine. |
List<String> |
getNodesBlackList()
Get the nodes black list. |
List<String> |
getNodesWhiteList()
Get the nodes white list. |
static int |
round(int nb,
int step)
Return the closest number, with a certain step. |
void |
setNodesBlackList(List<String> nodes)
Set the nodes black list. |
void |
setNodesWhiteList(List<String> nodes)
Set the nodes white list. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int DEFAULT_CPU_STEP
| Constructor Detail |
|---|
public ConfigurationAdapter()
| Method Detail |
|---|
public abstract Configuration extractConfiguration()
throws MonitoringException
MonitoringException - if an error occurs
public static int round(int nb,
int step)
nb - the numberstep - the step
public static int getCPUCapacity(int mhz,
int nbCPU)
mhz - The CPU frequencynbCPU - the number of CPU allocated
public static int getCPUConsumption(float cpuPct,
Node host)
cpuPct - the percentage of CPU consumed by the virtual machinehost - the host of the virtual machine
public void setNodesBlackList(List<String> nodes)
nodes - the listpublic List<String> getNodesBlackList()
public void setNodesWhiteList(List<String> nodes)
nodes - the listpublic List<String> getNodesWhiteList()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||