|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.novell.zos.jdl.ScheduleSpec
public class ScheduleSpec
The ScheduleSpec class defines one or more Joblets to be scheduled and run on resources.
A ScheduleSpec instance is passed to the Job's schedule()
or scheduleSweep()
.
schedule()
creates the Joblets and schedules Joblets to run on resources.
Example of using a ScheduleSpec to schedule a single Joblet:
s = ScheduleSpec() s.setJobletClass(MyJoblet) self.schedule(s)This class can only allowed be used in the Job class for passing to
schedule()
or for getting the list of matching resources from getMatchingResources()
.
Field Summary | |
---|---|
static int |
ACTIVE_NODE_SET
Used to specify that the Joblet set will be constructed after applying resource constraints to the set of active/online resources. |
static int |
PROVISIONABLE_NODE_SET
Used to specify that the Joblet set will be constructed after applying resource constraints to the set of provisionable resources. |
Constructor Summary | |
---|---|
ScheduleSpec()
Construct a ScheduleSpec with defaults. |
Method Summary | |
---|---|
int |
getCount()
Retrieve number of Joblets created for this set. |
void |
setConstraint(Constraint constraint)
Assign a Constraint for resource selection. |
void |
setConstraint(java.lang.String constraint)
Assign a Constraint in XML for resource selection. |
void |
setCount(int count)
Assign the maximum number of Joblets to create for this set. |
void |
setJobletArgs(org.python.core.PyDictionary facts)
Define facts for this jobletargs namespace for
a Joblet . |
void |
setJobletClass(org.python.core.PyClass jobletClass)
Assign the Joblet Class to use for Joblet execution on the resource. |
void |
setJobletFacts(org.python.core.PyDictionary facts)
Define additional joblet facts for this ScheduleSpec. |
void |
setUseNodeSet(int nodeSet)
If set to PROVISIONABLE_NODE_SET, the Joblet set will be constructed after applying resource constraints to the set of provisionable resources. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static int ACTIVE_NODE_SET
public static int PROVISIONABLE_NODE_SET
Constructor Detail |
---|
public ScheduleSpec()
Method Detail |
---|
public void setCount(int count)
setMaxJobleSize
in ParameterSpace
.
count
- Number of Joblets to createpublic int getCount()
scheduleSweep()
.
public void setJobletClass(org.python.core.PyClass jobletClass)
jobletClass
- Reference to Joblet class to execute on nodepublic void setConstraint(Constraint constraint)
constraint = EqConstraint() constraint.setFact("resource.os.name") constraint.setValue("Windows XP") ScheduleSpec = ScheduleSpec() ScheduleSpec.setJobletClass(MyJoblet) ScheduleSpec.setConstraint(constraint)Note: This can only be used with
scheduleSweep()
.
Constraints are not currently supported with schedule()
.
constraint
- Constraint for resource selectionpublic void setConstraint(java.lang.String constraint)
ScheduleSpec = ScheduleSpec() ScheduleSpec.setJobletClass(MyJoblet) ScheduleSpec.setConstraint("Note: This can only be used with")
scheduleSweep()
.
Constraints are not currently supported with schedule()
.
constraint
- Constraint as XML for resource selectionpublic void setUseNodeSet(int nodeSet)
ScheduleSpec = ScheduleSpec() ScheduleSpec.setUseNodeSet(ScheduleSpec.PROVISIONABLE_NODE_SET)
nodeSet
- true to reference provisionable set of nodes rather than
active set.public void setJobletArgs(org.python.core.PyDictionary facts)
jobletargs
namespace for
a Joblet
.
Each Joblet created for this schedulet gets a copy of this
set of Joblet arguments facts.
facts
- Dictionary of facts to add to each Joblet's factsetpublic void setJobletFacts(org.python.core.PyDictionary facts)
facts
- Dictionary of facts to add to each Joblet factset
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |