Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.ow2.jasmine.vmm.api
Interface HostMXBean

All Superinterfaces:
  ManagedResourceMXBean

    public interface HostMXBean

extends ManagedResourceMXBean

Management interface of a physical host acting as a container of virtual machines by way of a hypervisor.

The `ObjectName` for identifying a HostMXBean follows the following template:

> org.ow2.jasmine.vmm.api:type=Host,name=<pathname> ,hostname=<hostname>

The notifications that can be emitted by a HostMXBean are as follows

- NotificationTypes.VM_NEW when a new VM is created
- NotificationTypes.VM_DEL when a VM is deleted
- NotificationTypes.PERF_REPORT: periodic performance reports

Nested Class Summary
`static class` | `HostMXBean.PerfMetric` Defines the different performance metrics that can be retrieved from a host

Method Summary
`void` | `configurePerfMonitor(java.util.Set<HostMXBean.PerfMetric> metricsOfInterest, long periodMillis)` Deprecated.
`VirtualMachineMXBean` | `createVM(VMConfigSpec vmSpec, boolean sync)` Creates a new virtual machine on this host.
`java.util.Map<java.lang.String,java.lang.String>` | `getCPUInfo()` Returns the information about the CPU on this host.
`float` | `getCPULoad()` Returns the aggregate CPU load of the host
`long` | `getFreeMemoryMB()` Returns the free memory capacity of this host in MBytes
`java.lang.String` | `getHostName()` Returns the DNS name of the host
`java.util.Map<java.lang.String,java.lang.String>` | `getHypervisorInfo()` Returns properties of the hypervisor active for this host
`float[]` | `getLoadPerCPU()` Returns the current load on each CPU core of the host
`int` | `getNumCPU()` Return the number of CPU cores on the host
`java.util.List<VirtualMachineMXBean>` | `getResidentVMs()` Returns the VMs resident on this host
`ServerPoolMXBean` | `getServerPool()` Returns the server pool this host belongs to
`long` | `getTotalMemoryMB()` Returns the total memory capacity of this host in MBytes
`java.util.Map<java.lang.String,java.lang.Float>` | `getVMCPULoads()` Return the CPU load of every VM hosted on this host
`VirtualMachineImageStoreMXBean` | `getVMImageStore()` Returns the VM image store associated with this host
`java.util.Map<java.lang.String,ResourceUsage>` | `getVMResourceUsage()` Returns the current resource usage (CPU, memory, network, disk I/O) for all VM residing on this host

Methods inherited from interface org.ow2.jasmine.vmm.api.ManagedResourceMXBean
`getObjectName, getPath`

Method Detail

### getServerPool

    ServerPoolMXBean getServerPool()

  Returns the server pool this host belongs to

  Returns:

### getHostName

    java.lang.String getHostName()

  Returns the DNS name of the host

  Returns:

### getHypervisorInfo

    java.util.Map<java.lang.String,java.lang.String> getHypervisorInfo()

  Returns properties of the hypervisor active for this host

  Returns:

### getNumCPU

    int getNumCPU()

  Return the number of CPU cores on the host

  Returns:

### getCPUInfo

    java.util.Map<java.lang.String,java.lang.String> getCPUInfo()

  Returns the information about the CPU on this host. The following properties are returned: model, speed and vendor.

  Returns:

### getResidentVMs

    java.util.List<VirtualMachineMXBean> getResidentVMs()

  Returns the VMs resident on this host

  Returns:

### getTotalMemoryMB

    long getTotalMemoryMB()

  Returns the total memory capacity of this host in MBytes

  Returns:

### getFreeMemoryMB

    long getFreeMemoryMB()

  Returns the free memory capacity of this host in MBytes

  Returns:

### getLoadPerCPU

    float[] getLoadPerCPU()

  Returns the current load on each CPU core of the host

  Returns:

### getCPULoad

    float getCPULoad()

  Returns the aggregate CPU load of the host

  Returns:

### getVMCPULoads

    java.util.Map<java.lang.String,java.lang.Float> getVMCPULoads()

  Return the CPU load of every VM hosted on this host

  Returns:
    a map of CPU loads, as percentages, keyed by VM labels

### createVM

    VirtualMachineMXBean createVM(VMConfigSpec vmSpec,
                                  boolean sync)
                                  throws InsufficientResourcesException,
                                         InvalidVMConfigException,
                                         VMMException

  Creates a new virtual machine on this host. Upon successful creation a notification of type NotificationTypes.VM_NEW will be emitted by the HostMXBean on which the VM has been created.

  Parameters:
    `vmSpec` - initial configuration of the virtual machine
    `sync` - if true the call will return once the VM has been created
  Returns:
    the management interface of the created VM if `sync` is true, null otherwise
  Throws:
    `InsufficientResourcesException` - raised if not enough resources are available to create the VM
    `InvalidVMConfigException` - raised if the VM configuration is invalid
    `VMMException`

### getVMImageStore

    VirtualMachineImageStoreMXBean getVMImageStore()

  Returns the VM image store associated with this host

  Returns:

### getVMResourceUsage

    java.util.Map<java.lang.String,ResourceUsage> getVMResourceUsage()

  Returns the current resource usage (CPU, memory, network, disk I/O) for all VM residing on this host

  Returns:
    a map of ResourceUsage keyed by the VM label

### configurePerfMonitor

    @Deprecated
    void configurePerfMonitor(java.util.Set<HostMXBean.PerfMetric> metricsOfInterest,
                                         long periodMillis)

  Deprecated.

  Configure the reporting of performance metrics as JMX notifications.

  Parameters:
    `metricsOfInterest` - defines the metrics of interest
    `periodMillis` - the period of reporting in milliseconds. If this value is equal or less than zero, the reporting is disabled

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 OW2 Consortium. All Rights Reserved.