public abstract class AbstractScheduler extends java.lang.Object implements Scheduler
Scheduler.ComputingResult, Scheduler.SchedulerResult
Modifier and Type | Field and Description |
---|---|
protected int |
id
Id to serialize configuration and reconfiguration into a particular file name.
|
protected int |
planGraphDepth
The depth of the graph of the reconfiguration actions.
|
protected boolean |
rpAborted
Indicates if the reconfiguration plan has been aborted
|
Modifier | Constructor and Description |
---|---|
protected |
AbstractScheduler()
Constructor initializing fields and creating the source configuration regarding xHosts.
|
Modifier and Type | Method and Description |
---|---|
protected abstract void |
applyReconfigurationPlan()
Applies the reconfiguration plan from source model to dest model.
|
Scheduler.SchedulerResult |
checkAndReconfigure(java.util.Collection<XHost> hostsToCheck)
Core implementation
|
protected java.util.Collection<XVM> |
getMigratingVMs() |
protected boolean |
ongoingMigrations()
Indicates if there are still some ongoing migrations.
|
void |
relocateVM(java.lang.String vmName,
java.lang.String sourceName,
java.lang.String destName)
Relocates a VM.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
computeReconfigurationPlan
protected boolean rpAborted
protected int planGraphDepth
protected int id
protected AbstractScheduler()
protected abstract void applyReconfigurationPlan()
protected boolean ongoingMigrations()
protected java.util.Collection<XVM> getMigratingVMs()
public Scheduler.SchedulerResult checkAndReconfigure(java.util.Collection<XHost> hostsToCheck)
checkAndReconfigure
in interface Scheduler
hostsToCheck
- The XHost to check for violationspublic void relocateVM(java.lang.String vmName, java.lang.String sourceName, java.lang.String destName)
vmName
- vm namesourceName
- source configuration namedestName
- destination configuration name