hu.mta.sztaki.lpds.cloud.simulator.iaas.vmscheduling
Class Scheduler
java.lang.Object
hu.mta.sztaki.lpds.cloud.simulator.iaas.vmscheduling.Scheduler
- Direct Known Subclasses:
- FirstFitScheduler
public abstract class Scheduler
- extends Object
- Author:
- "Gabor Kecskemeti, Laboratory of Parallel and Distributed Systems,
MTA SZTAKI (c) 2012"
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
parent
protected final IaaSService parent
queue
protected List<QueueingData> queue
totalQueued
protected AlterableResourceConstraints totalQueued
publicTQ
protected UnalterableConstraintsPropagator publicTQ
orderedPMcache
private ArrayList<PhysicalMachine> orderedPMcache
pmCacheLen
private int pmCacheLen
queueListeners
private ArrayList<Scheduler.QueueingEvent> queueListeners
minimumSchedulerRequirement
private ConstantConstraints minimumSchedulerRequirement
freeResourcesSinceLastSchedule
private AlterableResourceConstraints freeResourcesSinceLastSchedule
pmComparator
public static final Comparator<PhysicalMachine> pmComparator
pmstateChanged
protected PhysicalMachine.StateChangeListener pmstateChanged
freeCapacity
protected VMManager.CapacityChangeEvent<ResourceConstraints> freeCapacity
Scheduler
public Scheduler(IaaSService parent)
scheduleVMrequest
public final void scheduleVMrequest(VirtualMachine[] vms,
ResourceConstraints rc,
Repository vaSource,
HashMap<String,Object> schedulingConstraints)
throws VMManager.VMManagementException
- Throws:
VMManager.VMManagementException
dropVMrequest
public final boolean dropVMrequest(VirtualMachine vm)
getTotalQueued
public ResourceConstraints getTotalQueued()
getQueueLength
public int getQueueLength()
manageQueueRemoval
protected void manageQueueRemoval(QueueingData qd)
- Removes an arbitrary item from the queue
- Parameters:
qd
-
manageQueueRemoval
protected QueueingData manageQueueRemoval()
- Removes the head of the queue
updateTotalQueuedAfterRemoval
private void updateTotalQueuedAfterRemoval(QueueingData qd)
subscribeQueueingEvents
public final void subscribeQueueingEvents(Scheduler.QueueingEvent e)
unsubscribeQueueingEvents
public final void unsubscribeQueueingEvents(Scheduler.QueueingEvent e)
notifyListeners
protected void notifyListeners()
getQueuedVMs
public final List<VirtualMachine> getQueuedVMs()
invokeRealScheduler
private void invokeRealScheduler()
scheduleQueued
protected abstract ConstantConstraints scheduleQueued()
Copyright © 2012–2015 University of Innsbruck & MTA SZTAKI. All rights reserved.