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, RoundRobinScheduler
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 ResourceConstraints totalQueued
orderedPMcache
private ArrayList<PhysicalMachine> orderedPMcache
pmCacheLen
private int pmCacheLen
queueListeners
private ArrayList<Scheduler.QueueingEvent> queueListeners
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
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()
scheduleQueued
protected abstract void scheduleQueued()
Copyright © 2012–2015 University of Innsbruck & MTA SZTAKI. All rights reserved.