Class BackfillMod

  extended byunm.maui.sched.BackfillMod
All Implemented Interfaces:
java.util.EventListener, MauiListener, SchedListener, java.io.Serializable

public class BackfillMod
extends java.lang.Object
implements SchedListener, java.io.Serializable

Basic Scheduler.

See Also:
Serialized Form

Field Summary
protected  int bfdepth
          Backfill depth.
static java.lang.String bfDepthProperty
protected  java.lang.String prefix
          Properties prefix.
protected  java.lang.String resClass
          JobReservation class string.
static java.lang.String resClassProperty
protected  Scheduler scheduler
          The scheduler.
Constructor Summary
Method Summary
 void assignProperties(java.lang.String prefix, java.util.Properties props)
          Set properties.
 void event(SchedEvent evt)
          Schedule jobs.
protected  Reservation makeReservation(Job job, long starttime)
          Core method to make reservation(s) (potentially spanning RMs) for a given schedulable object.
We ask the matcher object for available nodes/slots to run the job (potentially at a given starttime).
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail


public static final transient java.lang.String bfDepthProperty
See Also:
Constant Field Values


public static final transient java.lang.String resClassProperty
See Also:
Constant Field Values


protected Scheduler scheduler
The scheduler.


protected transient int bfdepth
Backfill depth.


protected transient java.lang.String resClass
JobReservation class string.


protected java.lang.String prefix
Properties prefix.

Constructor Detail


public BackfillMod()

Method Detail


public void assignProperties(java.lang.String prefix,
                             java.util.Properties props)
Set properties.

Specified by:
assignProperties in interface MauiListener
prefix - String properties prefix
props - Properties


public void event(SchedEvent evt)
Schedule jobs.

Scheduling is done in basic FIFO order (NOTE: jobs have been previously prioritized and are sorted in order of priority in the queue). First we clear any job reservations made previously, then, starting at the head of the queue, we ask the question can we make an immediate reservation for the job? If so, we do and continue this process until we cannot immediately schedule the next highest priority job.
In addition, any reservations that are made are immediately activated (which means that the jobs are submitted to and started on the relevant RMs).

Specified by:
event in interface SchedListener
evt - SchedEvent
See Also:


protected Reservation makeReservation(Job job,
                                      long starttime)
Core method to make reservation(s) (potentially spanning RMs) for a given schedulable object.
We ask the matcher object for available nodes/slots to run the job (potentially at a given starttime). Make a reservation if we get enough nodes/slots. NOTE: as with all internal scheduler/RM methods it is assumed that the JobFilter has successfully parsed the job requirements and hasn't allowed a job with bogus parameter values through...

job - Job
starttime - time when we want the job to start (if < 0, then starttime isn't a concern)
Reservation or null if reservation could not be made