org.ow2.jasmine.vmm.api
Interface ServerPoolMXBean

All Superinterfaces:
ManagedResourceMXBean

public interface ServerPoolMXBean
extends ManagedResourceMXBean

Management interface of a Server Pool. A Server Pool is a management unit acting as a container of physical hosts and virtual machines. A Server Pool is homogeneous with regard to the virtualization technology used by its member hosts. Live or cold migration of virtual machines between hosts is allowed only if the source and target host belong to the same server pool.

The ObjectName for identifying a ServerPoolMXBean follows the following template:

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


Method Summary
 HostMXBean addHost(java.util.Map<java.lang.String,java.lang.String> attributes)
          Add a new Host to the server pool
 void deleteHost(HostMXBean host)
          Delete a host from the server pool
 java.util.Map<java.lang.String,java.lang.String> getAttributes()
          Return the attributes of the server pool
 java.lang.String getHypervisor()
          Returns the hypervisor common to every host of this pool
 java.util.List<HostMXBean> getManagedHosts()
          Returns the physical hosts belong to the server pool
 java.lang.String getName()
          Return the symbolic name of the server pool
 VirtualMachineImageStoreMXBean getVMImageStore()
          Returns the image stores belonging to this server pool
 void moveHost(HostMXBean host, ServerPoolMXBean pool)
          move a host to a different server pool
 VirtualMachineMXBean provisionVM(VMConfigSpec vmSpec, java.util.Map<java.lang.String,java.lang.String> constraints, boolean sync)
          Provisions a new virtual machine.
 void setProvisioningPolicy(java.lang.String policyId)
          Sets the provisioning policy of this domain
 
Methods inherited from interface org.ow2.jasmine.vmm.api.ManagedResourceMXBean
getObjectName, getPath
 

Method Detail

getName

java.lang.String getName()
Return the symbolic name of the server pool

Returns:

getAttributes

java.util.Map<java.lang.String,java.lang.String> getAttributes()
Return the attributes of the server pool

Returns:
the attributes of the server pool

provisionVM

VirtualMachineMXBean provisionVM(VMConfigSpec vmSpec,
                                 java.util.Map<java.lang.String,java.lang.String> constraints,
                                 boolean sync)
                                 throws InsufficientResourcesException,
                                        InvalidVMConfigException,
                                        VMMException
Provisions a new virtual machine. The host on which the VM will be created will depend on the provisioning policy active for Server Pool. 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
constraints - constraints on the placement of the VM
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

setProvisioningPolicy

void setProvisioningPolicy(java.lang.String policyId)
Sets the provisioning policy of this domain

Parameters:
policyId -

getManagedHosts

java.util.List<HostMXBean> getManagedHosts()
Returns the physical hosts belong to the server pool

Returns:

getVMImageStore

VirtualMachineImageStoreMXBean getVMImageStore()
Returns the image stores belonging to this server pool

Returns:

addHost

HostMXBean addHost(java.util.Map<java.lang.String,java.lang.String> attributes)
                   throws VMMException
Add a new Host to the server pool

Parameters:
attributes - attributes of the new host
Returns:
the added hostMXBean
Throws:
VMMException

deleteHost

void deleteHost(HostMXBean host)
                throws VMMException
Delete a host from the server pool

Parameters:
host - host to delete
Throws:
VMMException

getHypervisor

java.lang.String getHypervisor()
Returns the hypervisor common to every host of this pool

Returns:
hypervisor type

moveHost

void moveHost(HostMXBean host,
              ServerPoolMXBean pool)
              throws VMMException
move a host to a different server pool

Parameters:
host - host to delete
pool - destination pool
Throws:
VMMException


Copyright © 2011 OW2 Consortium. All Rights Reserved.