@Sample(name="vi-top",
description="an ESX-Top-like application that lets administrators specify the CPU and memory counters by name to obtain metrics for a specified host")
public class VITop
extends ConnectedVimServiceBase
VITop
This sample is an ESX-Top-like application that lets administrators specify
the CPU and memory counters by name to obtain metrics for a specified host
Parameters:
url [required] : url of the web service
username [required] : username for the authentication
password [required] : password for the authentication
host [required] : name of the host
cpu [required] : CPU counter name
e.g. usage, ready, guaranteed
memory [required] : memory counter name
e.g. usage, granted
Command Line:
run.bat com.vmware.performance.VITop
--url [webservice url] --username [user] --password [password]
--host [FQDN_host_name]
--cpu [cpu_counter_name] --memory [mem_counter_name]
ConnectedVimServiceBase.ConnectionExceptionPROP_ME_NAME, SVC_INST_NAME| Constructor and Description |
|---|
VITop() |
| Modifier and Type | Method and Description |
|---|---|
void |
run() |
void |
setCpu(java.lang.String cpu) |
void |
setHostname(java.lang.String hostname) |
void |
setMemory(java.lang.String memory) |
basicConnectionFromConnection, connect, disconnect, getServiceInstanceReference, setConnection, setHostConnection@Option(name="host",
description="name of the host")
public void setHostname(java.lang.String hostname)
@Option(name="cpu",
description="CPU counter name [usage|ready|guaranteed]")
public void setCpu(java.lang.String cpu)
@Option(name="memory",
description="memory counter name [usage|granted]")
public void setMemory(java.lang.String memory)
@Action
public void run()
throws com.vmware.vim25.RuntimeFaultFaultMsg,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException,
java.lang.IllegalAccessException,
java.lang.InterruptedException
com.vmware.vim25.RuntimeFaultFaultMsgjava.lang.reflect.InvocationTargetExceptionjava.lang.NoSuchMethodExceptionjava.lang.IllegalAccessExceptionjava.lang.InterruptedException