hu.mta.sztaki.lpds.cloud.simulator.io
Class VirtualAppliance

java.lang.Object
  extended by hu.mta.sztaki.lpds.cloud.simulator.io.StorageObject
      extended by hu.mta.sztaki.lpds.cloud.simulator.io.VirtualAppliance

public class VirtualAppliance
extends StorageObject

Virtual appliances represent functional virtual machine images in the system.

Author:
"Gabor Kecskemeti, Distributed and Parallel Systems Group, University of Innsbruck (c) 2013" "Gabor Kecskemeti, Laboratory of Parallel and Distributed Systems, MTA SZTAKI (c) 2012"

Field Summary
private  long bgNetworkLoad
          The background network load expected to be simulated between the appliance's hosting repository and the PM that hosts the VM while the VM runs its tasks.
private  double startupProcessing
          The number of processing instructions to be done during the startup of the VM that utilizes this VA.
 
Fields inherited from class hu.mta.sztaki.lpds.cloud.simulator.io.StorageObject
id, size
 
Constructor Summary
VirtualAppliance(String id, double startupProcess, long nl)
          Creates a virtual appliance with default size and variance (for details, see StorageObject)
VirtualAppliance(String id, double startupProcess, long nl, boolean vary, long reqDisk)
          Creates a virtual appliance with custom size and size variance.
 
Method Summary
 long getBgNetworkLoad()
          Allows to determine the background network load expected to be simulated between the appliance's hosting repository and the PM that hosts the VM while the VM runs its tasks.
 double getStartupProcessing()
          Allows to determine the number of processing instructions to be done during the startup of the VM that utilizes this VA.
 VirtualAppliance newCopy(String myid)
          creates an object that holds the exact copy of the current virtual appliance with a different id Please note this copy is not going to be registered in any repositories (unlike the other VA), nor will it be used by any virtual machines.
 void setBgNetworkLoad(long bgNetworkLoad)
          Allows to set the background network load expected to be simulated between the appliance's hosting repository and the PM that hosts the VM while the VM runs its tasks.
private  void setDetails(double startupProcess, long nl)
          Allows updating the appliance's properties in a single step.
 void setStartupProcessing(double startupProcessing)
          Allows to set the number of processing instructions to be done during the startup of the VM that utilizes this VA.
 String toString()
          Provides a compact output of all data represented in this VA.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

bgNetworkLoad

private long bgNetworkLoad
The background network load expected to be simulated between the appliance's hosting repository and the PM that hosts the VM while the VM runs its tasks. Unit: bytes/tick Ratinale: if the VM is backed by a shared storage, then all its disk operations (while doing compute intensive tasks) are expected to generate network activities as well.


startupProcessing

private double startupProcessing
The number of processing instructions to be done during the startup of the VM that utilizes this VA. unit: instructions

Constructor Detail

VirtualAppliance

public VirtualAppliance(String id,
                        double startupProcess,
                        long nl)
Creates a virtual appliance with default size and variance (for details, see StorageObject)

Parameters:
id - the id of the appliance
startupProcess - number of processing instructions on startup
nl - background network load while running tasks on a VM that has storage backed by a remote repository

VirtualAppliance

public VirtualAppliance(String id,
                        double startupProcess,
                        long nl,
                        boolean vary,
                        long reqDisk)
Creates a virtual appliance with custom size and size variance.

Parameters:
id - the id of the appliance
startupProcess - number of processing instructions on startup
nl - background network load while running tasks on a VM that has storage backed by a remote repository
vary - true if the requested appliance size is not fixed, false otherwise
reqDisk - the size of the disk image to host the virtual appliance (this might not be the actual size, but could be used for generating varying sizes according to the param vary. Unit: bytes.
Method Detail

setDetails

private void setDetails(double startupProcess,
                        long nl)
Allows updating the appliance's properties in a single step.

Parameters:
startupProcess - number of processing instructions on startup
nl - background network load while running tasks on a VM that has storage backed by a remote repository

newCopy

public VirtualAppliance newCopy(String myid)
creates an object that holds the exact copy of the current virtual appliance with a different id Please note this copy is not going to be registered in any repositories (unlike the other VA), nor will it be used by any virtual machines.

Overrides:
newCopy in class StorageObject
Parameters:
myid - the id of the new storage object
Returns:
the storage object that has the same size as this one but that has the new id given in myid

getBgNetworkLoad

public long getBgNetworkLoad()
Allows to determine the background network load expected to be simulated between the appliance's hosting repository and the PM that hosts the VM while the VM runs its tasks. Unit: bytes/tick


getStartupProcessing

public double getStartupProcessing()
Allows to determine the number of processing instructions to be done during the startup of the VM that utilizes this VA. unit: number of instructions


setBgNetworkLoad

public void setBgNetworkLoad(long bgNetworkLoad)
Allows to set the background network load expected to be simulated between the appliance's hosting repository and the PM that hosts the VM while the VM runs its tasks. Unit: bytes/tick Warning: handle with care, this has no effect on already running virtual machines


setStartupProcessing

public void setStartupProcessing(double startupProcessing)
Allows to set the number of processing instructions to be done during the startup of the VM that utilizes this VA. unit: number of instructions Warning: handle with care, this has no effect on already running virtual machines


toString

public String toString()
Provides a compact output of all data represented in this VA. Useful for debugging.

Overrides:
toString in class StorageObject


Copyright © 2012–2015 University of Innsbruck & MTA SZTAKI. All rights reserved.