gridbroker
Class Experiment

Object
  |
  +--gridbroker.Experiment

public class Experiment
extends Object

Experiment class acts as a placeholder for representing simulation experiment configuration that includes synthesized application (a set of Gridlets stored in GridletList) and user requirements such as D- and B-factor or deadline and budget constraints, and optimization strategy.

It provides methods for updating and querying the experiment parameters and status. The user entity invokes the broker entity and passes its requirements via the experiment object. On receiving an experiment from its user, the broker schedules Gridlets according to the optimization policy set for the experiment.

Version:
2.1, June 2003
Author:
Manzur Murshed and Rajkumar Buyya
Invariant:
$none

Field Summary
static int OPTIMIZE_COST
          Aims for Cost minimization
static int OPTIMIZE_COST_PLUS
          Aims for Cost minimization.
static int OPTIMIZE_COST_TIME
          Aims for Cost minimization and Time Optimisation if possible
static int OPTIMIZE_NONE
          Aims for NO minimization
static int OPTIMIZE_TIME
          Aims for Time minimization
 
Constructor Summary
Experiment(int id, GridletList glList, int optStrategy, boolean factorFlag, double D_value, double B_value, String reportFile, String[] resNameList)
          Allocates a new Experiment object
 
Method Summary
 double BudgetUtilizationFactor()
          Deprecated. As of GridBroker 2.1, replaced by getBudgetUtilFactor()
 boolean Get_DB_factor_flag()
          Deprecated. As of GridBroker 2.1, replaced by getFactorFlag()
 Accumulator getAllGridletLengthAccumulator()
          Accumulates the length of all the Gridlets
 Accumulator GetAllGridletsLengthAccumulator()
          Deprecated. As of GridBroker 2.1, replaced by getAllGridletLengthAccumulator()
 double GetB_factor()
          Deprecated. As of GridBroker 2.1, replaced by getBudgetFactor()
 double getBudget()
          Gets the experiment budget
 double GetBudget()
          Deprecated. As of GridBroker 2.1, replaced by getBudget()
 double getBudgetFactor()
          Gets the budget factor
 double getBudgetSpent()
          Gets the total budget spent on a successful Gridlets' execution.
 double GetBudgetSpent()
          Deprecated. As of GridBroker 2.1, replaced by getBudgetSpent()
 double getBudgetUtilFactor()
          Gets the budget utilization factor
 double GetD_factor()
          Deprecated. As of GridBroker 2.1, replaced by getDeadlineFactor()
 double getDeadline()
          Gets the experiment deadline
 double GetDeadline()
          Deprecated. As of GridBroker 2.1, replaced by getDeadline()
 double getDeadlineFactor()
          Gets the deadline factor
 double getDeadlineTime()
          Gets the deadline time
 double GetDeadlineTime()
          Deprecated. As of GridBroker 2.1, replaced by getDeadlineTime()
 double getEndTime()
          Gets the experiment end time
 double GetEndTime()
          Deprecated. As of GridBroker 2.1, replaced by getEndTime()
 int getExperimentID()
          Gets the experiment ID
 boolean getFactorFlag()
          Gets the deadline and budget factor flag
 double getGridletCompletionFactor()
          Gets the completion ratio based on the number of successful Gridlets with the total Gridlets.
 GridletList getGridletList()
          Gets a list of Gridlets
 GridletList GetGridletList()
          Deprecated. As of GridBroker 2.1, replaced by getGridletList()
 int GetID()
          Deprecated. As of GridBroker 2.1, replaced by getExperimentID()
 int GetNoOfGridlets()
          Deprecated. As of GridBroker 2.1, replaced by getNumGridlet()
 int GetNoOfSuccessfulGridlets()
          Deprecated. As of GridBroker 2.1, replaced by getNumSuccessfulGridlet()
 int getNumGridlet()
          Gets the number of Gridlets
 int getNumSuccessfulGridlet()
          Gets the total number of successful Gridlets
 int getOptimizationStrategy()
          Gets the optimization strategy represented in an integer number
 int GetOptimizationStrategy()
          Deprecated. As of GridBroker 2.1, replaced by getOptimizationStrategy()
 String getOptimizationStrategyName()
          Gets the optimization strategy represented in a String object
 String GetOptimizationStrategyName()
          Deprecated. As of GridBroker 2.1, replaced by getOptimizationStrategyName()
 String getReportFileName()
          Gets the name of a report file
 String GetReportFileName()
          Deprecated. As of GridBroker 2.1, replaced by getReportFileName()
 String[] getResourceNameList()
          Gets a list of resources' names
 String[] GetResourcesNameList()
          Deprecated. As of GridBroker 2.1, replaced by getResourceNameList()
 double getStartTime()
          Gets the experiment start time
 double GetStartTime()
          Deprecated. As of GridBroker 2.1, replaced by getStartTime()
 double getTimeUtilFactor()
          Gets the time utilization factor
 double GridletCompletionFactor()
          Deprecated. As of GridBroker 2.1, replaced by getGridletCompletionFactor()
 boolean isSuccessful()
          Checks whether the Gridlets have been executed successfully or not
 boolean IsSuccessful()
          Deprecated. As of GridBroker 2.1, replaced by isSuccessful()
 void setBudget(double budget)
          Sets the experiment budget
 void SetBudget(double budget)
          Deprecated. As of GridBroker 2.1, replaced by setBudget(double)
 void setDeadline(double deadline)
          Sets the experiment deadline
 void SetDeadline(double deadline)
          Deprecated. As of GridBroker 2.1, replaced by setDeadline(double)
 void setDeadlineBudget(double deadline, double budget)
          Sets the experiment deadline and budget
 void SetDeadlineBudget(double deadline, double budget)
          Deprecated. As of GridBroker 2.1, replaced by setDeadlineBudget(double, double)
 void setEndTime()
          Sets the experiment end time
 void SetEndTime()
          Deprecated. As of GridBroker 2.1, replaced by setEndTime()
 void setStartTime()
          Sets the current time as the experiment start time
 void SetStartTime()
          Deprecated. As of GridBroker 2.1, replaced by setStartTime()
 double TimeUtilizationFactor()
          Deprecated. As of GridBroker 2.1, replaced by getTimeUtilFactor()
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OPTIMIZE_COST

public static final int OPTIMIZE_COST
Aims for Cost minimization

See Also:
Constant Field Values

OPTIMIZE_COST_PLUS

public static final int OPTIMIZE_COST_PLUS
Aims for Cost minimization. However, powerful machines come first if they have the same cost.

See Also:
Constant Field Values

OPTIMIZE_COST_TIME

public static final int OPTIMIZE_COST_TIME
Aims for Cost minimization and Time Optimisation if possible

See Also:
Constant Field Values

OPTIMIZE_TIME

public static final int OPTIMIZE_TIME
Aims for Time minimization

See Also:
Constant Field Values

OPTIMIZE_NONE

public static final int OPTIMIZE_NONE
Aims for NO minimization

See Also:
Constant Field Values
Constructor Detail

Experiment

public Experiment(int id,
                  GridletList glList,
                  int optStrategy,
                  boolean factorFlag,
                  double D_value,
                  double B_value,
                  String reportFile,
                  String[] resNameList)
Allocates a new Experiment object

Parameters:
id - experiment ID
glList - A list containing Gridlets that has details on the list of the jobs
optStrategy - the optimization strategy
factorFlag - true if the next two parameters are d-factor and b-factor, and the User expects the Broker to determine actual deadline and budget based on these two relaxation parameters
D_value - if factorFlag is true, then it is d-factor, else it is deadline value
B_value - if factorFlag is true, then it is b-factor, else it is budget value
reportFile - the name of the file into which scheduling report is to placed
resNameList - a list of resource names
Pre Condition:
id >= 0, glList != null, reportFile != null, resNameList != null
Post Condition:
$none
Method Detail

GetID

public int GetID()
Deprecated. As of GridBroker 2.1, replaced by getExperimentID()

Gets the experiment ID

Returns:
the experiment ID
Pre Condition:
$none
Post Condition:
$result >= 0

getExperimentID

public int getExperimentID()
Gets the experiment ID

Returns:
the experiment ID
Pre Condition:
$none
Post Condition:
$result >= 0

GetGridletList

public GridletList GetGridletList()
Deprecated. As of GridBroker 2.1, replaced by getGridletList()

Gets a list of Gridlets

Returns:
an object of GridletList
See Also:
GridletList
Pre Condition:
$none
Post Condition:
$result != null

getGridletList

public GridletList getGridletList()
Gets a list of Gridlets

Returns:
an object of GridletList
See Also:
GridletList
Pre Condition:
$none
Post Condition:
$result != null

GetResourcesNameList

public String[] GetResourcesNameList()
Deprecated. As of GridBroker 2.1, replaced by getResourceNameList()

Gets a list of resources' names

Returns:
an array of String the contains resources' names
Pre Condition:
$none
Post Condition:
$result != null

getResourceNameList

public String[] getResourceNameList()
Gets a list of resources' names

Returns:
an array of String the contains resources' names
Pre Condition:
$none
Post Condition:
$result != null

GetOptimizationStrategy

public int GetOptimizationStrategy()
Deprecated. As of GridBroker 2.1, replaced by getOptimizationStrategy()

Gets the optimization strategy represented in an integer number

Returns:
the optimization strategy
Pre Condition:
$none
Post Condition:
$none

getOptimizationStrategy

public int getOptimizationStrategy()
Gets the optimization strategy represented in an integer number

Returns:
the optimization strategy
Pre Condition:
$none
Post Condition:
$none

GetOptimizationStrategyName

public String GetOptimizationStrategyName()
Deprecated. As of GridBroker 2.1, replaced by getOptimizationStrategyName()

Gets the optimization strategy represented in a String object

Returns:
the optimization strategy or null if no strategy detected
Pre Condition:
$none
Post Condition:
$none

getOptimizationStrategyName

public String getOptimizationStrategyName()
Gets the optimization strategy represented in a String object

Returns:
the optimization strategy or null if no strategy detected
Pre Condition:
$none
Post Condition:
$none

Get_DB_factor_flag

public boolean Get_DB_factor_flag()
Deprecated. As of GridBroker 2.1, replaced by getFactorFlag()

Gets the deadline and budget factor flag

Returns:
if true, then computes the experiment deadline and budget from d-factor and b-factor
Pre Condition:
$none
Post Condition:
$none

getFactorFlag

public boolean getFactorFlag()
Gets the deadline and budget factor flag

Returns:
if true, then computes the experiment deadline and budget from d-factor and b-factor
Pre Condition:
$none
Post Condition:
$none

GetB_factor

public double GetB_factor()
Deprecated. As of GridBroker 2.1, replaced by getBudgetFactor()

Gets the budget factor

Returns:
the budget factor
Pre Condition:
$none
Post Condition:
$result >= 0.0

getBudgetFactor

public double getBudgetFactor()
Gets the budget factor

Returns:
the budget factor
Pre Condition:
$none
Post Condition:
$result >= 0.0

GetD_factor

public double GetD_factor()
Deprecated. As of GridBroker 2.1, replaced by getDeadlineFactor()

Gets the deadline factor

Returns:
the deadline factor
Pre Condition:
$none
Post Condition:
$result >= 0.0

getDeadlineFactor

public double getDeadlineFactor()
Gets the deadline factor

Pre Condition:
$none
Post Condition:
$result >= 0.0

SetDeadline

public void SetDeadline(double deadline)
Deprecated. As of GridBroker 2.1, replaced by setDeadline(double)

Sets the experiment deadline

Parameters:
deadline - the deadline value
Pre Condition:
deadline >= 0.0
Post Condition:
$none

setDeadline

public void setDeadline(double deadline)
Sets the experiment deadline

Parameters:
deadline - the deadline value
Pre Condition:
deadline >= 0.0
Post Condition:
$none

GetDeadline

public double GetDeadline()
Deprecated. As of GridBroker 2.1, replaced by getDeadline()

Gets the experiment deadline

Returns:
the deadline value
Pre Condition:
$none
Post Condition:
$result >= 0.0

getDeadline

public double getDeadline()
Gets the experiment deadline

Returns:
the deadline value
Pre Condition:
$none
Post Condition:
$result >= 0.0

GetDeadlineTime

public double GetDeadlineTime()
Deprecated. As of GridBroker 2.1, replaced by getDeadlineTime()

Gets the deadline time

Returns:
the deadline time
Pre Condition:
$none
Post Condition:
$result >= 0.0

getDeadlineTime

public double getDeadlineTime()
Gets the deadline time

Returns:
the deadline time
Pre Condition:
$none
Post Condition:
$result >= 0.0

SetBudget

public void SetBudget(double budget)
Deprecated. As of GridBroker 2.1, replaced by setBudget(double)

Sets the experiment budget

Parameters:
budget - the budget value
Pre Condition:
budget >= 0.0
Post Condition:
$none

setBudget

public void setBudget(double budget)
Sets the experiment budget

Parameters:
budget - the budget value
Pre Condition:
budget >= 0.0
Post Condition:
$none

GetBudget

public double GetBudget()
Deprecated. As of GridBroker 2.1, replaced by getBudget()

Gets the experiment budget

Returns:
the budget value
Pre Condition:
$none
Post Condition:
$result >= 0.0

getBudget

public double getBudget()
Gets the experiment budget

Returns:
the budget value
Pre Condition:
$none
Post Condition:
$result >= 0.0

SetDeadlineBudget

public void SetDeadlineBudget(double deadline,
                              double budget)
Deprecated. As of GridBroker 2.1, replaced by setDeadlineBudget(double, double)

Sets the experiment deadline and budget

Parameters:
deadline - the deadline value
budget - the budget value
Pre Condition:
deadline >= 0.0, budget >= 0.0
Post Condition:
$none

setDeadlineBudget

public void setDeadlineBudget(double deadline,
                              double budget)
Sets the experiment deadline and budget

Parameters:
deadline - the deadline value
budget - the budget value
Pre Condition:
deadline >= 0.0, budget >= 0.0
Post Condition:
$none

GetReportFileName

public String GetReportFileName()
Deprecated. As of GridBroker 2.1, replaced by getReportFileName()

Gets the name of a report file

Returns:
the file name
Pre Condition:
$none
Post Condition:
$result != null

getReportFileName

public String getReportFileName()
Gets the name of a report file

Returns:
the file name
Pre Condition:
$none
Post Condition:
$result != null

SetStartTime

public void SetStartTime()
Deprecated. As of GridBroker 2.1, replaced by setStartTime()

Sets the current time as the experiment start time

Pre Condition:
$none
Post Condition:
$none

setStartTime

public void setStartTime()
Sets the current time as the experiment start time

Pre Condition:
$none
Post Condition:
$none

GetStartTime

public double GetStartTime()
Deprecated. As of GridBroker 2.1, replaced by getStartTime()

Gets the experiment start time

Returns:
the start time
Pre Condition:
$none
Post Condition:
$result >= 0.0

getStartTime

public double getStartTime()
Gets the experiment start time

Returns:
the start time
Pre Condition:
$none
Post Condition:
$result >= 0.0

SetEndTime

public void SetEndTime()
Deprecated. As of GridBroker 2.1, replaced by setEndTime()

Sets the experiment end time

Pre Condition:
$none
Post Condition:
$none

setEndTime

public void setEndTime()
Sets the experiment end time

Pre Condition:
$none
Post Condition:
$none

GetEndTime

public double GetEndTime()
Deprecated. As of GridBroker 2.1, replaced by getEndTime()

Gets the experiment end time

Returns:
the end time
Pre Condition:
$none
Post Condition:
$result >= 0.0

getEndTime

public double getEndTime()
Gets the experiment end time

Returns:
the end time
Pre Condition:
$none
Post Condition:
$result >= 0.0

GetNoOfGridlets

public int GetNoOfGridlets()
Deprecated. As of GridBroker 2.1, replaced by getNumGridlet()

Gets the number of Gridlets

Returns:
the gridlet size or 0 if it is empty
Pre Condition:
$none
Post Condition:
$result >= 0

getNumGridlet

public int getNumGridlet()
Gets the number of Gridlets

Returns:
the gridlet size or 0 if it is empty
Pre Condition:
$none
Post Condition:
$result >= 0

GetBudgetSpent

public double GetBudgetSpent()
Deprecated. As of GridBroker 2.1, replaced by getBudgetSpent()

Gets the total budget spent on a successful Gridlets' execution. Calculated based on the actual CPU time * Cost per second of a Gridlet.

Returns:
the budget spent
Pre Condition:
$none
Post Condition:
$result >= 0

getBudgetSpent

public double getBudgetSpent()
Gets the total budget spent on a successful Gridlets' execution. Calculated based on the actual CPU time * Cost per second of a Gridlet.

Returns:
the budget spent
Pre Condition:
$none
Post Condition:
$result >= 0

GetNoOfSuccessfulGridlets

public int GetNoOfSuccessfulGridlets()
Deprecated. As of GridBroker 2.1, replaced by getNumSuccessfulGridlet()

Gets the total number of successful Gridlets

Returns:
the total number or 0 if none
Pre Condition:
$none
Post Condition:
$result >= 0

getNumSuccessfulGridlet

public int getNumSuccessfulGridlet()
Gets the total number of successful Gridlets

Returns:
the total number or 0 if none
Pre Condition:
$none
Post Condition:
$result >= 0

IsSuccessful

public boolean IsSuccessful()
Deprecated. As of GridBroker 2.1, replaced by isSuccessful()

Checks whether the Gridlets have been executed successfully or not

Returns:
true if the Gridlets are finished, otherwise false
Pre Condition:
$none
Post Condition:
$none

isSuccessful

public boolean isSuccessful()
Checks whether the Gridlets have been executed successfully or not

Returns:
true if the Gridlets are finished, otherwise false
Pre Condition:
$none
Post Condition:
$none

GridletCompletionFactor

public double GridletCompletionFactor()
Deprecated. As of GridBroker 2.1, replaced by getGridletCompletionFactor()

Gets the completion ratio based on the number of successful Gridlets with the total Gridlets.

Returns:
the completion ratio
Pre Condition:
$none
Post Condition:
$result >= 0.0

getGridletCompletionFactor

public double getGridletCompletionFactor()
Gets the completion ratio based on the number of successful Gridlets with the total Gridlets.

Returns:
the completion ratio
Pre Condition:
$none
Post Condition:
$result >= 0.0

TimeUtilizationFactor

public double TimeUtilizationFactor()
Deprecated. As of GridBroker 2.1, replaced by getTimeUtilFactor()

Gets the time utilization factor

Returns:
the time utilization factor
Pre Condition:
$none
Post Condition:
$none

getTimeUtilFactor

public double getTimeUtilFactor()
Gets the time utilization factor

Returns:
the time utilization factor
Pre Condition:
$none
Post Condition:
$none

BudgetUtilizationFactor

public double BudgetUtilizationFactor()
Deprecated. As of GridBroker 2.1, replaced by getBudgetUtilFactor()

Gets the budget utilization factor

Returns:
the budget utilization factor
Pre Condition:
$none
Post Condition:
$none

getBudgetUtilFactor

public double getBudgetUtilFactor()
Gets the budget utilization factor

Returns:
the budget utilization factor
Pre Condition:
$none
Post Condition:
$none

GetAllGridletsLengthAccumulator

public Accumulator GetAllGridletsLengthAccumulator()
Deprecated. As of GridBroker 2.1, replaced by getAllGridletLengthAccumulator()

Accumulates the length of all the Gridlets

Returns:
an Accumulator object
See Also:
Accumulator
Pre Condition:
$none
Post Condition:
$result != null

getAllGridletLengthAccumulator

public Accumulator getAllGridletLengthAccumulator()
Accumulates the length of all the Gridlets

Returns:
an Accumulator object
See Also:
Accumulator
Pre Condition:
$none
Post Condition:
$result != null