com.novell.zos.jdl
Class VMHostInfo

java.lang.Object
  extended by com.novell.zos.jdl.GridObjectInfo
      extended by com.novell.zos.jdl.VMHostInfo
Direct Known Subclasses:
VmHostClusterInfo

public class VMHostInfo
extends GridObjectInfo

The VmHostInfo class is a representation of a VM host grid object. This class provides accessors and setters to the Vm Host facts and operations to control the state of the VM host object.

Example to retrieve an existing instance of a VmHostInfo and initiate a soft shutdown on it.

      vmhost = getMatrix().getGridObject(TYPE_VMHOST,"MyVmHost")
      vmhost.shutdown()
 


Method Summary
 GridObjectInfo createVbridge(java.lang.String bridgeName)
          Create a new Vbridge Grid Object associated with this physical resource.
 void discoverVMs()
          Start a discovery operation for this Vm Host.
 GridObjectInfo getVbridge(java.lang.String bridgeName)
          Fetch a Vbridge Grid Object associated with this physical resource.
 void shutdown()
          Initiate a soft shutdown of this Vm host.
 void shutdown(boolean hard)
          Shutdown this Vm host specifying a hard or soft shutdown.
 void start()
          Initiate a start action on this Vm host.
 
Methods inherited from class com.novell.zos.jdl.GridObjectInfo
deleteFact, factExists, getFact, getFact, getFactLastModified, getFactNames, refresh, setArrayFact, setBooleanArrayFact, setDateArrayFact, setDateFact, setFact, setIntegerArrayFact, setRealArrayFact, setStringArrayFact, setTimeArrayFact, setTimeFact
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

shutdown

public void shutdown()
Initiate a soft shutdown of this Vm host.

This will softly shutdown any running VMs on this host and put the Vm Host in a state of not accepting provisioning actions. A soft shutdown will wait for the agent to be idle.


shutdown

public void shutdown(boolean hard)
Shutdown this Vm host specifying a hard or soft shutdown.

This will shutdown any running VMs on this host and put the Vm Host in a state of not accepting provisioning actions.

Parameters:
hard - true to shutdown hard, false to initiate a soft shutdown. A hard shutdown is immediate (no migration, agent idle wait, etc)

start

public void start()
Initiate a start action on this Vm host.

Enable the Vm Host as ready for provisioning actions.


discoverVMs

public void discoverVMs()
Start a discovery operation for this Vm Host.

This action can create and delete VM's, reset attributes on VMs, delete the referenced VmHost and mark an existing VM as needing to be re-synced.


createVbridge

public GridObjectInfo createVbridge(java.lang.String bridgeName)
Create a new Vbridge Grid Object associated with this physical resource.

The bridge name in this case is the host-local name, not the globally qualified bridge name. (i.e. "br0", not "host1_br0")

Parameters:
bridgeName - Name of the bridge to create
Returns:
Vbridge Grid Object representing the new bridge
Throws:
java.lang.Exception - if operation is not supported or error occurs in creation

getVbridge

public GridObjectInfo getVbridge(java.lang.String bridgeName)
Fetch a Vbridge Grid Object associated with this physical resource.

The bridge name in this case is the host-local name, not the globally qualified bridge name. (i.e. "br0", not "host1_br0")

Parameters:
bridgeName - Name of the bridge to fetch
Returns:
Vbridge Grid Object representing the bridge
Throws:
java.lang.Exception - if operation is not supported or error occurs in lookup


Copyright (c) 2011 Novell, Inc. All rights reserved.