be.ac.ua.broker.allocation
Class Allocator

java.lang.Object
  extended by be.ac.ua.broker.allocation.Allocator

public class Allocator
extends java.lang.Object

This class is used during the resource allocation phase of the broker. For every instance on which certain task hours were scheduled in the previous phase of the broker, is determined what pricing model will be used and the actual prices are coupled to the schedule. There are different options available, only on-demand instances, no spot instances, spot-enabled (which uses the spot model to determine the bid) and spot-optimal (which used the actual spot price history to determine the bid).

Author:
Vermeersch Kurt

Constructor Summary
Allocator(boolean uSE_TASK_HOURS)
          Constructor for Allocator
 
Method Summary
 SchedulerResultCollection allocate(java.lang.String version, SchedulerResultCollection results)
          Assign pricing models to the resources of the schedule in a way that the total cost price is minimized.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Allocator

public Allocator(boolean uSE_TASK_HOURS)
Constructor for Allocator

Parameters:
uSE_TASK_HOURS - whether the first workload model is being used
Method Detail

allocate

public SchedulerResultCollection allocate(java.lang.String version,
                                          SchedulerResultCollection results)
                                   throws InstanceNotAvailableException,
                                          InvalidInputException
Assign pricing models to the resources of the schedule in a way that the total cost price is minimized.

Parameters:
version - the allocation scheme option to use
results - the original schedule
Returns:
the updated schedule marked with actual prices
Throws:
InstanceNotAvailableException
InvalidInputException